Set-up for the finite difference solution method

def FD(self):
    """
    Set-up for the finite difference solution method
    """
    if self.Verbose:
      print("Finite Difference Solution Technique")
    # Used to check for coeff_matrix here, but now doing so in self.bc_check()
    # called by f1d and f2d at the start
    # 
    # Define a stress-based qs = q0
    # But only if the latter has not already been defined
    # (e.g., by the getters and setters)
    try:
      self.qs
    except:
      self.qs = self.q0.copy()
      # Remove self.q0 to avoid issues with multiply-defined inputs
      # q0 is the parsable input to either a qs grid or contains (x,(y),q)
      del self.q0
    # Give it x and y dimensions for help with plotting tools
    # (not implemented internally, but a help with external methods)
    self.x = np.arange(self.dx/2., self.dx * self.qs.shape[0], self.dx)
    if self.dimension == 2:
      self.y = np.arange(self.dy/2., self.dy * self.qs.shape[1], self.dy)
    # Is there a solver defined
    try:
      self.Solver # See if it exists already
    except:
      # Well, will fail if it doesn't see this, maybe not the most reasonable
      # error message.
      if self.filename:
        self.Solver = self.configGet("string", "numerical", "Solver")
      else:
        sys.exit("No solver defined!")
    # Check consistency of size if coeff array was loaded
    if self.filename:
      # In the case that it is iterative, find the convergence criterion
      self.iterative_ConvergenceTolerance = self.configGet("float", "numerical", "ConvergenceTolerance")    
      # Try to import Te grid or scalar for the finite difference solution
      try:
        self.Te = self.configGet("float", "input", "ElasticThickness", optional=False)
        if self.Te is None:
          Tepath = self.configGet("string", "input", "ElasticThickness", optional=False)
          self.Te = Tepath
        else:
          Tepath = None
      except:
        Tepath = self.configGet("string", "input", "ElasticThickness", optional=False)
        self.Te = Tepath
      if self.Te is None:
        if self.coeff_matrix is not None:
          pass
        else:
          # Have to bring this out here in case it was discovered in the 
          # try statement that there is no value given
          sys.exit("No input elastic thickness or coefficient matrix supplied.")
    # or if getter/setter
    if type(self.Te) == str: 
      # Try to import Te grid or scalar for the finite difference solution
      Tepath = self.Te
    else:
      Tepath = None # in case no self.filename present (like for GRASS GIS)
    # If there is a Tepath, import Te
    # Assume that even if a coeff_matrix is defined
    # That the user wants Te if they gave the path
    if Tepath:
      self.Te = self.loadFile(self.Te, close_on_fail = False)
      if self.Te is None:
        print("Requested Te file is provided but cannot be located.")
        print("No scalar elastic thickness is provided in configuration file")
        print("(Typo in path to input Te grid?)")
        if self.coeff_matrix is not None:
          print("But a coefficient matrix has been found.")
          print("Calculations will be carried forward using it.")
        else:
          print("Exiting.")
          sys.exit()

      # Check that Te is the proper size if it was loaded
      # Will be array if it was loaded
      if self.Te.any():
        self.TeArraySizeCheck()