Automated ranking of reaction schemes, Sobol scans, PSO and kinetic fitting
A free GitHub account is required to access the program code in this repository; send us your GitHub username.
You can use Scale-up Suite 2 and RunScript Automation with the example code in this project.
You will need Python installed to run the scripts provided here. That’s because they’re Python scripts :) You will see that these could be written in many other languages and Python is just a good example.
About
This repository contains code you can use to reproduce the live demo in the Scale-up Systems webinar of 14 August 2023 here. Before coding, we recommend that you review the recording, slides and short movie of the plots available in the Resources site at the above link. Once you have got started (below), you can edit and apply this workflow or parts of it to your own models. Note that Scale-up Systems can only support the code that you download from this repository and cannot support you with e.g. debugging any edits that you make later.
Get started
- Click the [View on Github] button, or navigate here
- In the SchemeSobolPSOFit folder, download each of the files (except the ReadMe) and save them in the same folder on your own machine. The xlsx is a batch reaction model; in principle, any Dynochem reaction model could be used
- Make sure that you have access to a RunScript Automation license (grab this license using your Scale-up Manager)
- pip install SALib - this module supports the global sensitivity analysis (GSA) part of the workflow; the particle swarm code (PSO) is inside SchemeSobolPSOFinalFit.py:
pip install SALib
- Run the python script called SchemeSobolPSOFinalFit.py and the code will begin to work on the batch reaction model, trying alternative reaction schemes from the file schemes.csv
- On completion (maybe 10-15 minutes later, depending on the speed of your machine), several reports and plots summarizing results for each scheme (3 schemes in total) will appear in the folder. Each run produces files with a unique 5-digit identifier in the title of all of the output files.
- To learn more about what’s going on in the script:
- open the SchemeSobolPSOFinalFit.py script in an editor, e.g. Visual Studio Code
- review the global parameters defined at the top of the code; experiment with these, noting the comments in the code
- save and rerun the code after making changes
- if you like reading code, read the whole project; the structure of the main program is quite logical and sequential.
See this KB Article for additional information specific to RunScript Automation. Enjoy!