Changeset 1552 for trunk


Ignore:
Timestamp:
04/08/22 11:28:51 (2 years ago)
Author:
aclsce
Message:

Modified to use CMIP6 workflow for non CMIP6 runs.

Location:
trunk/libIGCM
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/libIGCM/libIGCM_comp/libIGCM_comp.ksh

    r1545 r1552  
    15661566        # Modify path from dr2xml_{compname}.xml 
    15671567        if [ X${config_Post_dr2xmlIPSL} = XTRUE ]; then 
    1568           ${libIGCM}/libIGCM_post/xios_parser.py -v modifydr2xmlIPSL --newPath ${CMIP6_DIR} --splitLastDate ${EndYear_p1} --JobName ${config_UserChoices_JobName} --ModelName ${config_UserChoices_ModelName} --ModelVersion ${config_UserChoices_LongName} --file dr2xml_${compname}.xml 
     1568          ${libIGCM}/libIGCM_post/xios_parser.py -v modifydr2xmlIPSL --newPath ${CMIP6_DIR} --splitLastDate ${EndYear_p1} --JobName ${config_UserChoices_JobName} --ModelName ${config_UserChoices_ModelName} --ModelVersion ${config_UserChoices_LongName} --ExperimentName ${config_UserChoices_ExperimentName} --file dr2xml_${compname}.xml 
    15691569        else 
    15701570          ${libIGCM}/libIGCM_post/xios_parser.py -v modifyPath --newPath ${CMIP6_DIR} --file dr2xml_${compname}.xml 
  • trunk/libIGCM/libIGCM_post/xios_parser.py

    r1537 r1552  
    215215                            if childElem.attrib.get('name') == 'source_id': 
    216216                               childElem.text = args.ModelName[0] 
     217                if args.ExperimentName is not None: 
     218                    for childElem in elem.iter(tag='variable'): 
     219                        if args.verbosity >= 2: print childElem.tag, childElem.attrib 
     220                        if childElem.attrib.get('name') is not None: 
     221                            if childElem.attrib.get('name') == 'experiment': 
     222                               childElem.text = args.ExperimentName[0] 
    217223 
    218224 
     
    364370        parser_check.add_argument('--ModelName', nargs=1, required=False, help='Name of the model to be added in the name of file produced from dr2xml_file type') 
    365371        parser_check.add_argument('--ModelVersion', nargs=1, required=False, help='Model version to be added in global attributes of files produced from dr2xml_file type') 
     372        parser_check.add_argument('--ExperimentName',nargs=1, required=False, help='Name of the experiment') 
    366373        parser_check.add_argument('--file', nargs='+', required=True, help='XIOS xml dr2xml_file type') 
    367374        parser_check.add_argument('--splitLastDate', nargs=1, required=False, help='Date to be used as split_last_date') 
Note: See TracChangeset for help on using the changeset viewer.