Scripts
Last updated
Was this helpful?
Last updated
Was this helpful?
This section shows any Python scripts associated with the project/scenario. The Scripts
accordion shows the following information per script (see ):
Name: name provided by the user to indentify the script.
Type: "file/script". Provided for legacy reasons (script is now a dedicated type).
Filename: name of the Python script (*.py) file on the hard drive.
Scenario: name of the scenario if the script is associated with a scenario.
Modfied: last date the script was modified.
Figure 15 - "Scripts" section of Iota
Users can import Python scripts into the project/scenario by clicking on the Import
button located at the right corner of accordion (see ). A pop-up window will be shown so the user can enter the following fields for the file/script:
Name (required): a name for the script. If none is provided, the file name will be used.
Description (optional): a description for the script.
Scenario (optional): any scenario associated with the script.
Choose File: the button opens a file browser window that allows users to select the Python script (*.py) to be imported.
Note that the python scripts to be imported in this section must contain the function def run(scenario):
defined in the .py file. See the documentation of the for a more detailed description of the functionality available from the provided by the scripting interface.
Figure 16 - Import Script window
Clicking on the Edit button launches a window where the user can rename the script.
Clicking on the Delete button launches a window prompting the user to confirm deletion.
The scripts associated with the project/scenario are available in the section of the Coarse-graining page so that users can select them to be automatically executed immediately after the coarse-graining run has completed. Also, the user can run scripts using the Iota IPython Terminal (for more details, see in the .