当前位置: 首页>>代码示例>>Python>>正文


Python core.Script类代码示例

本文整理汇总了Python中pylabcontrol.core.Script的典型用法代码示例。如果您正苦于以下问题:Python Script类的具体用法?Python Script怎么用?Python Script使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了Script类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

 def __init__(self, name=None, settings=None, log_function = None, data_path = None):
     """
     Example of a script
     Args:
         name (optional): name of script, if empty same as class name
         settings (optional): settings for this script, if empty same as default settings
     """
     Script.__init__(self, name, settings, log_function= log_function, data_path = data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:8,代码来源:test_script.py

示例2: __init__

 def __init__(self, instruments = None, scripts = None, name = None, settings = None, log_function = None, data_path = None):
     """
     Example of a script that emits a QT signal for the gui
     Args:
         name (optional): name of script, if empty same as class name
         settings (optional): settings for this script, if empty same as default settings
     """
     Script.__init__(self, name, settings = settings, instruments = instruments, scripts = scripts, log_function= log_function, data_path = data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:8,代码来源:set_magnetic_coils.py

示例3: __init__

    def __init__(self, instruments, scripts=None, name=None, settings=None, log_function=None, data_path=None):
        """
        init script function see superclass for details on the parameters
        """
        Script.__init__(self, name, settings=settings, scripts=scripts, instruments=instruments,
                        log_function=log_function, data_path=data_path)

        self.data = None
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:8,代码来源:read_temperature_lakeshore.py

示例4: __init__

 def __init__(self, scripts, instruments = None, name = None, settings = None, log_function = None, data_path = None):
     """
     Initializes the script
     Args:
         name (optional): name of script, if empty same as class name
         settings (optional): settings for this script, if empty same as default settings
     """
     self.scan_label = 'Motor Position [um]'
     Script.__init__(self, name, settings, instruments, scripts, log_function= log_function, data_path = data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:9,代码来源:autofocus.py

示例5: __init__

 def __init__(self, instruments, scripts = None, name=None, settings=None, log_function=None, data_path = None):
     Script.__init__(self, name, settings=settings, scripts=scripts, instruments=instruments, log_function=log_function, data_path = data_path)
     # defines which daqs contain the input and output based on user selection of daq interface
     if self.settings['daq_type'] == 'PCI':
         self.daq_in = self.instruments['NI6259']['instance']
         self.daq_out = self.instruments['NI6259']['instance']
     elif self.settings['daq_type'] == 'cDAQ':
         self.daq_in = self.instruments['NI9402']['instance']
         self.daq_out = self.instruments['NI9263']['instance']
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:9,代码来源:esr_dithering.py

示例6: __init__

 def __init__(self, instruments = None, scripts = None, name = None, settings = None, log_function = None, data_path = None):
     """
     Sets up script and sends width and height settings to camera
     Args:
         name (optional): name of script, if empty same as class name
         settings (optional): settings for this script, if empty same as default settings
     """
     Script.__init__(self, name, settings = settings, instruments = instruments, scripts = scripts, log_function= log_function, data_path = data_path)
     self.instruments['Camera']['instance'].update({'width': self.settings['width'], 'height': self.settings['height']})
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:9,代码来源:take_image_camera.py

示例7: __init__

    def __init__(self, scripts, name = None, settings = None, log_function = None, timeout = 1000000000, data_path = None):
        self._recording = False
        self._timeout = timeout

        Script.__init__(self, name, settings, scripts = scripts, log_function= log_function, data_path = data_path)

        self.data = deque()

        self._sweep_values =  list({'frequency' : [], 'x' : [], 'y' : [], 'phase': [], 'r':[]}.keys())
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:9,代码来源:zi_high_res_sweep.py

示例8: __init__

    def __init__(self, instruments = None, name = None, settings = None, scripts = None, log_function = None, data_path = None):
        """
        Example of a script that emits a QT signal for the gui
        Args:
            name (optional): name of script, if empty same as class name
            settings (optional): settings for this script, if empty same as default settings
        """
        Script.__init__(self, name, settings = settings, instruments = instruments, scripts = scripts, log_function= log_function, data_path = data_path)

        self.data = {'baseline_image': [], 'new_image': [], 'image_extent': [], 'correlation_image': []}
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:10,代码来源:correlate_images.py

示例9: __init__

    def __init__(self, instruments, scripts=None, name=None, settings=None, log_function=None, data_path=None):
        """
        Example of a script that emits a QT signal for the gui
        Args:
            name (optional): name of script, if empty same as class name
            settings (optional): settings for this script, if empty same as default settings
        """
        Script.__init__(self, name, settings=settings, scripts=scripts, instruments=instruments,
                        log_function=log_function, data_path=data_path)

        self.data = {'counts': deque(), 'laser_power': deque(), 'normalized_counts': deque(), 'laser_power2': deque()}
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:11,代码来源:daq_read_counter.py

示例10: __init__

    def __init__(self, instruments, name = None, settings = None, log_function = None, data_path = None):
        """
        Example of a script that makes use of an instrument
        Args:
            instruments: instruments the script will make use of
            name (optional): name of script, if empty same as class name
            settings (optional): settings for this script, if empty same as default settings
        """

        # call init of superclass
        Script.__init__(self, name, settings, instruments, log_function= log_function, data_path = data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:11,代码来源:light_control.py

示例11: __init__

    def __init__(self, instruments, scripts, name=None, settings=None, log_function=None, data_path=None):
        """
        Standard script initialization
        Args:
            name (optional): name of script, if empty same as class name
            settings (optional): settings for this script, if empty same as default settings
        """
        self._DEFAULT_SETTINGS += PulsedExperimentBaseScript._DEFAULT_SETTINGS

        Script.__init__(self, name, settings=settings, scripts=scripts, instruments=instruments,
                        log_function=log_function, data_path=data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:11,代码来源:pulsed_experiment_base_script.py

示例12: __init__

    def __init__(self, instruments, scripts=None, name=None, settings=None, log_function=None, data_path=None):
        """
        Example of a script that emits a QT signal for the gui
        Args:
            name (optional): name of script, if empty same as class name
            settings (optional): settings for this script, if empty same as default settings
        """
        Script.__init__(self, name, settings=settings, scripts=scripts, instruments=instruments,
                        log_function=log_function, data_path=data_path)

        self.data_to_plot = {'voltage': deque(maxlen = self.settings['max_len_to_plot'])}
        self.data['voltage'] = list()
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:12,代码来源:daq_read_ai.py

示例13: __init__

 def __init__(self, instruments = None, scripts = None, name = None, settings = None, log_function = None, data_path = None):
     """
     Example of a script that emits a QT signal for the gui
     Args:
         name (optional): name of script, if empty same as class name
         settings (optional): settings for this script, if empty same as default settings
     """
     Script.__init__(self, name, settings = settings, instruments = instruments, scripts = scripts, log_function= log_function, data_path = data_path)
     if self.settings['daq_type'] == 'PCI':
         self.daq_out = self.instruments['NI6259_laser_power']['instance']
     elif self.settings['daq_type'] == 'cDAQ':
         self.daq_out = self.instruments['NI9263_laser_power']['instance']
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:12,代码来源:set_laser_power.py

示例14: __init__

    def __init__(self, scripts, name=None, settings=None, log_function=None, data_path=None):
        '''
        Initializes GalvoScan script for use in gui

        Args:
            instruments: list of instrument objects
            name: name to give to instantiated script object
            settings: dictionary of new settings to pass in to override defaults
            log_function: log function passed from the gui to direct log calls to the gui log
            data_path: path to save data

        '''
        self._DEFAULT_SETTINGS = self._DEFAULT_SETTINGS + GalvoScanGeneric._DEFAULT_SETTINGS
        Script.__init__(self, name, settings=settings, scripts=scripts, log_function=log_function, data_path = data_path)
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:14,代码来源:galvo_scan_osci.py

示例15: __init__

    def __init__(self, instruments, name = None, settings = None, log_function = None, timeout = 1000000000, data_path = None):

        self._recording = False
        self._timeout = timeout

        Script.__init__(self, name, settings, instruments, log_function= log_function, data_path = data_path)

        self.sweeper = self.instruments['zihf2']['instance'].daq.sweep(self._timeout)
        self.sweeper.set('sweep/device', self.instruments['zihf2']['instance'].device)

        self.data = deque()

        # todo: clean this up! and plot data in gui!
        self._sweep_values =  list({'frequency' : [], 'x' : [], 'y' : [], 'phase': [], 'r':[]}.keys())
开发者ID:LISE-B26,项目名称:b26_toolkit,代码行数:14,代码来源:zi_sweeper.py


注:本文中的pylabcontrol.core.Script类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。