code: def get_subs_dict(self, qnodes=None):
          
          #d = self.qparams.copy()
          d = self.qparams
          d.update(self.optimize_params(qnodes=qnodes))
          # clean null values
          subs_dict = {k: v for k, v in d.items() if v is not None}
          #print("subs_dict:", subs_dict)
          return subs_dict
docs: Return substitution dict for replacements into the template
          Subclasses may want to customize this method.