Loading pysen/echo/phase_table.py +2 −1 Original line number Diff line number Diff line Loading @@ -29,7 +29,8 @@ def brute_force_interpolation(vals, xvals, yvals, x, y): def make_phase_table(phtab, polyfit=0, ncur=10, nphi=11, pos='p2', threshold=0.2): "make phase table" # #pylint: disable=too-many-locals, too-many-statements #FIXME: refactor this log = logging.getLogger() # data must come in same format Loading pysen/inout/reader.py +2 −1 Original line number Diff line number Diff line Loading @@ -811,7 +811,8 @@ def read_transmission(filename): def read_diffrun(filename, att_table=None): "read nse diffrun file" #pylint: disable=too-many-branches #pylint: disable=too-many-branches, too-many-statements #FIXME: refactor this monstrosity (read_diffrun) wavelength = 0.0 data_flag = False mon1_flag = False Loading pysen/inout/writer.py +4 −0 Original line number Diff line number Diff line Loading @@ -105,6 +105,8 @@ class DiffractionWriter(DiffractionScan): def save(self, outdir='.'): "convert read nexus file to diffrun .dat file" #pylint: disable=too-many-statements #FIXME: refactor this diffrun = self.make_filename(self.info['base']) with open(os.path.join(outdir, diffrun), 'wt', encoding='ascii') as fd: # Loading Loading @@ -294,6 +296,8 @@ class EchoWriter(EchoScan): def save(self, outdir='.'): "convert read nexus file to .echo file" #pylint: disable=too-many-statements #FIXME: refactor this echofile = self.make_filename(self.info['base']) with open(os.path.join(outdir, echofile), 'wt', encoding='ascii') as fd: # Loading pysen/plot/echo.py +2 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,8 @@ def plot_single_echo(ax, data, nptr, **kwargs): def plot_center_echo(hdfile, **kwargs): "echo plot" # #pylint: disable=too-many-locals, too-many-statements #FIXME: refactor this monster only_echo = kwargs.get('only_echo', False) resolution_plot = kwargs.get('resolution_plot', False) # implies -C savefile = kwargs.get('savefile', None) Loading pysen/plot/nseplot.py +0 −1 Original line number Diff line number Diff line Loading @@ -114,7 +114,6 @@ def action_detimage(filenames, **kwargs): savefig = kwargs.pop('savefig') for fname in filenames: try: base = os.path.basename(fname) plot_detimage(fname, **kwargs) except (OSError, RuntimeError) as e: logging.getLogger().error("%s",e) Loading Loading
pysen/echo/phase_table.py +2 −1 Original line number Diff line number Diff line Loading @@ -29,7 +29,8 @@ def brute_force_interpolation(vals, xvals, yvals, x, y): def make_phase_table(phtab, polyfit=0, ncur=10, nphi=11, pos='p2', threshold=0.2): "make phase table" # #pylint: disable=too-many-locals, too-many-statements #FIXME: refactor this log = logging.getLogger() # data must come in same format Loading
pysen/inout/reader.py +2 −1 Original line number Diff line number Diff line Loading @@ -811,7 +811,8 @@ def read_transmission(filename): def read_diffrun(filename, att_table=None): "read nse diffrun file" #pylint: disable=too-many-branches #pylint: disable=too-many-branches, too-many-statements #FIXME: refactor this monstrosity (read_diffrun) wavelength = 0.0 data_flag = False mon1_flag = False Loading
pysen/inout/writer.py +4 −0 Original line number Diff line number Diff line Loading @@ -105,6 +105,8 @@ class DiffractionWriter(DiffractionScan): def save(self, outdir='.'): "convert read nexus file to diffrun .dat file" #pylint: disable=too-many-statements #FIXME: refactor this diffrun = self.make_filename(self.info['base']) with open(os.path.join(outdir, diffrun), 'wt', encoding='ascii') as fd: # Loading Loading @@ -294,6 +296,8 @@ class EchoWriter(EchoScan): def save(self, outdir='.'): "convert read nexus file to .echo file" #pylint: disable=too-many-statements #FIXME: refactor this echofile = self.make_filename(self.info['base']) with open(os.path.join(outdir, echofile), 'wt', encoding='ascii') as fd: # Loading
pysen/plot/echo.py +2 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,8 @@ def plot_single_echo(ax, data, nptr, **kwargs): def plot_center_echo(hdfile, **kwargs): "echo plot" # #pylint: disable=too-many-locals, too-many-statements #FIXME: refactor this monster only_echo = kwargs.get('only_echo', False) resolution_plot = kwargs.get('resolution_plot', False) # implies -C savefile = kwargs.get('savefile', None) Loading
pysen/plot/nseplot.py +0 −1 Original line number Diff line number Diff line Loading @@ -114,7 +114,6 @@ def action_detimage(filenames, **kwargs): savefig = kwargs.pop('savefig') for fname in filenames: try: base = os.path.basename(fname) plot_detimage(fname, **kwargs) except (OSError, RuntimeError) as e: logging.getLogger().error("%s",e) Loading