kqcircuits.simulations.post_process

class kqcircuits.simulations.post_process.PostProcess(script, command='python', arguments='', folder='scripts', repeat_for_each=False, data_file_prefix=None, **data)[source]

Bases: object

Base class for adding post-processing scripts into the simulation batch

Parameters:
  • script – name of the post-processing script

  • command – command to run the post-processing script

  • arguments – command line arguments for the post-processing script given as string

  • folder – path where to look for the post-processing script file

  • repeat_for_each – whether to repeat the post-processing script for every simulation. The simulation json file name becomes the first command line argument.

  • data_file_prefix – prefix of the saved data file if data is given

  • data – additional data to be saved into a file. The data file name becomes the last command line argument.

get_command_line(path, json_filenames)[source]

Saves the data into file if needed and returns the command line to execute the post-processing script.

Parameters:
  • path – simulation folder path

  • json_filenames – list of paths to simulation json files

../_images/kqcircuits.simulations.post_process.png