tidy3d.web.Job

class tidy3d.web.Job(simulation, base_dir='out/', task_id=None, task_name=None, folder_name='default', draft=False, callback_url=None)

Container for single simulation and associated task.

simulation

Simulation being managed by the Job.

Type

Simulation

target_folder

Path to where this job stores its data. base_dir followed by task_id.

Type

str

task_id

Unique ID of task, can be found either on UI or through job.task_id.

Type

str

__init__(simulation, base_dir='out/', task_id=None, task_name=None, folder_name='default', draft=False, callback_url=None)

Construct.

Parameters
  • simulation (Simulation) – Simulation object to run.

  • base_dir (str, optional) – Base of path corresponding to where data for this job will be stored.

  • task_id (None, optional) – Unique ID of task, can be found either on UI or through job.task_id.

  • task_name (str, optional) – Custom name for the job.

  • folder_name (str, optional) – Server folder to hold the job.

  • draft (bool, optional) – If True, the job will be submitted but not run. It can then be visualized in the web UI and run from there when needed.

  • visualized in the web UI and run from there when needed. (be) –

  • callback_url (str, optional) – Http PUT url to receive simulation finish event. The body content is a json file with fields {'id', 'status', 'name', 'workUnit', 'solverVersion'}.

Methods

__init__(simulation[, base_dir, task_id, …])

Construct.

delete()

Deletes the Job from our server.

download_json([target_folder])

Download the json file associated with this job to target_folder.

download_results([target_folder])

Download the job results to target_folder.

get_info()

Returns dictionary containing Job metadata.

load_from_task_id(task_id[, base_dir, …])

Loads a Job from it’s task id.

load_results([target_folder])

Downloads data to target_folder, loads data into either saved simulation or newly created simulation.

monitor()

Prints status of Job in real time.