diff --git a/src/diffpy/labpdfproc/functions.py b/src/diffpy/labpdfproc/functions.py index 494be9b..03b7061 100644 --- a/src/diffpy/labpdfproc/functions.py +++ b/src/diffpy/labpdfproc/functions.py @@ -27,16 +27,6 @@ def _get_grid_points(self): self.grid = {(x, y) for x in xs for y in ys if x**2 + y**2 <= self.radius**2} self.total_points_in_grid = len(self.grid) - # def get_coordinate_index(self, coordinate): # I think we probably dont need this function? - # count = 0 - # for i, target in enumerate(self.grid): - # if coordinate == target: - # return i - # else: - # count += 1 - # if count >= len(self.grid): - # raise IndexError(f"WARNING: no coordinate {coordinate} found in coordinates list") - def set_distances_at_angle(self, angle): """ given an angle, set the distances from the grid points to the entry and exit coordinates diff --git a/src/diffpy/labpdfproc/labpdfprocapp.py b/src/diffpy/labpdfproc/labpdfprocapp.py index aedbd0a..986a95d 100644 --- a/src/diffpy/labpdfproc/labpdfprocapp.py +++ b/src/diffpy/labpdfproc/labpdfprocapp.py @@ -14,14 +14,14 @@ def get_args(override_cli_inputs=None): "input", nargs="+", help="The filename(s) or folder(s) of the datafile(s) to load. " - "Required.\nSupply a space-separated list of files or directories." + "Required.\nSupply a space-separated list of files or directories. " "Long lists can be supplied, one per line, in a file with name " "file_list.txt. If one or more directory is provided, all valid " "data-files in that directory will be processed. Examples of valid " "inputs are 'file.xy', 'data/file.xy', 'file.xy, data/file.xy', " - "'.' (load everything in the current directory), 'data' (load" - "everything in the folder ./data), 'data/file_list.txt' (load" - " the list of files contained in the text-file called " + "'.' (load everything in the current directory), 'data' (load " + "everything in the folder ./data), 'data/file_list.txt' (load " + "the list of files contained in the text-file called " "file_list.txt that can be found in the folder ./data), " "'./*.chi', 'data/*.chi' (load all files with extension .chi in the " "folder ./data).", @@ -45,7 +45,7 @@ def get_args(override_cli_inputs=None): "-o", "--output-directory", help="The name of the output directory. If not specified " - "then corrected files will be written to the current directory." + "then corrected files will be written to the current directory. " "If the specified directory doesn't exist it will be created.", default=None, ) @@ -64,7 +64,6 @@ def get_args(override_cli_inputs=None): action="store_true", help="The absorption correction will be output to a file if this " "flag is set. Default is that it is not output.", - default="tth", ) p.add_argument( "-f", diff --git a/src/diffpy/labpdfproc/tools.py b/src/diffpy/labpdfproc/tools.py index 5ada419..3100596 100644 --- a/src/diffpy/labpdfproc/tools.py +++ b/src/diffpy/labpdfproc/tools.py @@ -110,13 +110,12 @@ def set_wavelength(args): args argparse.Namespace the arguments from the parser + we raise a ValueError if the input wavelength is non-positive + or if the input anode_type is not one of the known sources + Returns ------- args argparse.Namespace - - we raise an ValueError if the input wavelength is non-positive - or if the input anode_type is not one of the known sources - """ if args.wavelength is not None and args.wavelength <= 0: raise ValueError(