code: def adjust_weights_resfile(self, resfile=None,original_ceiling=True):
          
          if resfile is not None:
              self.resfile = resfile
              self.__res = None
          phi_comps = self.phi_components
          self._adjust_weights_by_phi_components(phi_comps,original_ceiling)
docs: adjusts the weights by group of the observations based on the phi components
          in a pest residual file so that total phi is equal to the number of
          non-zero weighted observations
  
          Parameters
          ----------
          resfile : str
              residual file name.  If None, try to use a residual file
              with the Pst case name.  Default is None
          original_ceiling : bool
              flag to keep weights from increasing - this is generally a good idea.
              Default is True