MCPcopy Create free account
hub / github.com/NSLS2/PyXRF / get_new_param_from_file

Method get_new_param_from_file

pyxrf/model/parameters.py:344–357  ·  view source on GitHub ↗

Update parameters if new param_path is given. Parameters ---------- param_path : str path to save the file

(self, param_path)

Source from the content-addressed store, hash-verified

342 self.define_range()
343
344 def get_new_param_from_file(self, param_path):
345 """
346 Update parameters if new param_path is given.
347
348 Parameters
349 ----------
350 param_path : str
351 path to save the file
352 """
353 with open(param_path, "r") as json_data:
354 self.param_new = json.load(json_data)
355 self.create_spectrum_from_param_dict(reset=True)
356
357 logger.info("Elements read from file are: {}".format(self.element_list))
358
359 def update_new_param(self, param, reset=True):
360 """

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected