orangecontrib.tomwer.tests.TestAcquisition.Simulation#

class orangecontrib.tomwer.tests.TestAcquisition.Simulation(targetdir, manipulationId, finalState=4)#

Simulation is a simple class able to simulate an acquisition by copying files on a targetted directory.

Parameters:
  • targetdir – the folder where the acquisition is stored

  • manipulationId – the id of the simulation we want to simulate

  • finalState – when launched, the state to reach before stopping

Warning:

the targetted directory won’t be removed or cleaned during class destruction. This is to be managed by callers.

advanceTo(state)#

Reset the new advancement targetted

Parameters:

state – the new state to reach when run will be executed

advancement = {'acquisitionDone': 3, 'acquisitionRunning': 2, 'not started': -1, 'reconstructionLaunched': 4, 'starting-s0': 0, 'starting-s1': 1}#
copyInitialFiles()#

copy the .info file

createDark()#
createFinalXML(val)#

If activated, once all the file will be copied, this will create an .xml file into the output directory

createJPG()#
createOARJob()#
createParFile()#
createReconstructedFile()#
createVolfloat()#
createVolraw()#
run()#

Main function, run the acquisition through all states until finalState is reached

setSrcDestPatterns(srcPattern, destPattern)#

If setted, will set the .info and .xml files into a different folder

sigAdvancementChanged#

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.

signalCurrentState()#

Signal the actual state of the simulation