Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

as you can see, we have to explicitly select version of the actor. An alternative approach would be importing actors by embedding version as a part of package (sort of: from actor_demo.1_0.actor_demo import wrapper). Anyway, there is no simple way of making the very same workflow to be compatible with different versions of actor without altering workflow's code, environment variables, whatever the way of selecting the version we choose. 

Final directory structure

Below you can find final suggestion for the Python based layout

Code Block
3.25.0                                                                       - IMAS version
`-- coreprofiles2distsources                                                 - name of the actor (package for PIP)
    `-- 1.0.0                                                                - version of the actor (as specified in FC2K's project)
        |-- coreprofiles2distsources                                         - name of the actor (as visible inside Python)
        |   |-- __init__.py                                                  - makes an actor a module
        |   |-- code_parameters
        |   |   |-- cp_default.xml
        |   |   |-- cp_user.xml
        |   |   `-- cp_schema.xsd
        |   |-- native_wrapper                                               - all the native elements required by actor
        |   |   |-- bin
        |   |   |   |-- coreprofiles2distsourcesF.exe                        - standalone execution
        |   |   |   `-- coreprofiles2distsourcesF_opt.exe
        |   |   |-- build
        |   |   |-- lib
        |   |   |   |-- def
        |   |   |   |   `-- libcore_profiles_2_distribution_sources.a        - (do we need this one?)
        |   |   |   |-- libcoreprofiles2distsources_def.so                   - shared libraries
        |   |   |   |-- libcoreprofiles2distsources_opt.so
        |   |   |   |-- libcoreprofiles2distsources.so
        |   |   |   `-- opt
        |   |   |       `-- libcore_profiles_2_distribution_sources.a        - (do we need this one?)
        |   |   |-- lib_ext
        |   |   |   |-- def
        |   |   |   `-- opt
        |   |   |-- Makefile                                                 - Makefile for building all the native based part
        |   |   `-- src
        |   |       |-- fortrantools.f90                                     - Fortran based wrappers
        |   |       |-- FortranWrap.f90
        |   |       |-- RWTools.f90
        |   |       `-- standalone.f90
        |   `-- wrapper.py                                                   - this Python code contains Python based actor
        |-- MANIFEST.in                                                      - required by PIP
        |-- README.md                                                        - required by PIP
        |-- setup.cfg                                                        - required by PIP
        `-- setup.py                                                         - required by PIP

PyAL modifications

PyAL modifications

...

Alternative approach: One common installation of actor resources

...