Example #1
0
    def for_new_run(cls, paramfile, run_no, *args, **kwargs):
        from iota.components.iota_image import ImageImporter as Importer
        from iota.components.iota_processing import IOTAImageProcessor as Integrator

        # Initialize processing parameters
        from iota.components.iota_init import initialize_processing
        cls.info, cls.params = initialize_processing(paramfile, run_no)

        cls.importer = Importer(info=cls.info)
        cls.integrator = Integrator(iparams=cls.params)

        return cls(*args, **kwargs)
    def __init__(self, init, iterable, stage):
        ProcessingThreadBase.__init__(self,
                                      init=init,
                                      iterable=iterable,
                                      stage=stage)

        # Initialize importer and processor depending on backend
        if init.params.advanced.processing_backend == 'ha14':
            from iota.components.iota_image import OldImageImporter as Importer
            from iota.components.iota_cctbx_ha14 import Integrator
        else:
            from iota.components.iota_image import ImageImporter as Importer
            from iota.components.iota_processing import Integrator
        self.importer = Importer(init=init)
        self.integrator = Integrator(init=init)