BioSTEAMDevelopmentGroup / Bioindustrial-Park

BioSTEAM's Premier Repository for Biorefinery Models and Results
MIT License
36 stars 17 forks source link

Boilerplate biorefinery #21

Open yoelcortes opened 3 years ago

yoelcortes commented 3 years ago

We are in need of an "empty" project which can be used as a standard to create a production process for the biorefineries package. Note that following the boilerplate structure is not a requirement to contribute to the Bioindustrial-Park, but it would help keep consistency and standardization in the long run. The goal is to help and encourage new BioSTEAM users to contribute back their designs.

The following could be an advanced boilerplate:

biorefineries
    {biorefinery_name}
        data # All data used to model the process (e.g. csv files)
        results # All results of the process (e.g. figures, excel report)
        units # All unit operations (this could also just be a module)
        __init__.py # Imports units, key functions, and lazy loads chemicals and the system
        _analysis.py # Script used to create results
        _chemicals.py # Contains function to create Chemicals object
        _model.py # Contains a model with key metrics and parameters with their baseline distribution
        _process_settings.py # Contains a function to set heat utlities, CEPCI, and PowerUtility price
        _system.py # Contains a function to create the System object
        _tea.py # Contains a function to create the TEA object
        utils.py # Miscellaneous functions

The following could be a simplified boilerplate, for those who are not looking to reuse the code in other projects (so lazy loading and functions to recreate objects are not needed):

biorefineries
    {biorefinery_name}
        __init__.py # Imports everything
        _chemicals.py # Creates the Chemicals object
        _process_settings.py # Sets heat utlities, CEPCI, and PowerUtility price
        _system.py # Creates the System object
        _tea.py # Create the TEA class (if not reused from another project
        units.py # All unit operations
        utils.py # Miscellaneous functions

Each module in the boilerplate biorefinery should contain suggested imports and commented sections (e.g. make stream, make units, create system)

I hope to work on this on Jan 16th, please feel free to comment and contribute to the boilerplate biorefinery (directly or via pull requests). Changes are welcome (and expected) in the future.

Thanks, Have a nice day!

yalinli2 commented 3 years ago

This looks cool! We have been generally following this, but definitely good for new users. Some questions/comments:

Thanks!