From: W. Trevor King Date: Fri, 17 Aug 2012 14:37:17 +0000 (-0400) Subject: Add surface-matplotlib config option to pypiezo. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d6bc857594e308e1d153cd63b686fe88703cdead;p=pypiezo.git Add surface-matplotlib config option to pypiezo. Sometimes you want to troubleshoot surface detection without popping up a plot of every single piezo sweep. --- diff --git a/pypiezo/config.py b/pypiezo/config.py index f555b05..01cf06f 100644 --- a/pypiezo/config.py +++ b/pypiezo/config.py @@ -29,6 +29,10 @@ class PackageConfig (_h5config_tools.PackageConfig): name='matplotlib', help='Plot piezo motion using `matplotlib`.', default=False), + _config.BooleanSetting( + name='surface-matplotlib', + help='Plot surface positiong fit using `matplotlib`.', + default=False), ] diff --git a/pypiezo/surface.py b/pypiezo/surface.py index 6443ea2..0534613 100644 --- a/pypiezo/surface.py +++ b/pypiezo/surface.py @@ -209,7 +209,7 @@ def analyze_surface_position_data( full_output=True, maxfev=10000) _LOG.info('best fit parameters: %s' % (params,)) - if _package_config['matplotlib']: + if _package_config['surface-matplotlib']: if not _matplotlib: raise _matplotlib_import_error figure = _matplotlib_pyplot.figure()