Project

General

Profile

Create a campaign

To create a POMS campaign by using POMS configuration files created by the XML converter, the command is:

Project.py --create_campaign --ini_file ${USER}_<UserAnalysis>.ini --cfg_file ${USER}_<UserAnalysis>.cfg

It is needed to have a valid certificate or proxy.
If it is not available, but a valid kerberos ticket is available, project-py will create one.

An output example of the POMS Campaign creation is the following:

$ Project.py --create_campaign --ini_file vito_UserAnalysis.ini --cfg_file vito_UserAnalysis.cfg
2020-01-14 16:29:31,891 -  INFO - uploading cfg: /uboone/app/users/vito/poms_cfg/vito_UserAnalysis.cfg 
2020-01-14 16:29:32,316 -  INFO - uploaded ini /uboone/app/users/vito/poms_cfg/vito_UserAnalysis.ini
u'status: 201 Created'
u'upload: <uploaded_file_data>'
u'campaign_id: 3880'
u'campaign_stage_ids: '
[[4994, u'myanalysis']]
u'message: OK'

This shows information for the POMS Campaign just created,
such information are the campaign id and campaign stages (id and name) for each stage in the workflow.

In case in a previous POMS campaign creation a LoginSetup and or a JobType with the same name have already been created, there will be a warning, the POMS Campaign will be created using the existing LoginSetup and JobType.
This is shown in the following example:

$ Project.py --create_campaign --ini_file vito_demo_v2.ini --cfg_file vito_demo_v2.cfg
2020-01-14 16:29:31,891 -  INFO - uploading cfg: /uboone/app/users/vito/poms_cfg/vito_UserAnalysis.cfg 
2020-01-14 16:29:32,316 -  INFO - uploaded ini /uboone/app/users/vito/poms_cfg/vito_UserAnalysis.ini
u'status: 201 Created'
u'upload: <uploaded_file_data>'
u'campaign_id: 3880'
u'campaign_stage_ids: '
[[4994, u'myanalysis']]
u'message: '
[   u"Warning: LoginSetup 'vito_login' already exists and will not change.",
    u"Warning: JobType 'vito_demo_jobtype' already exists and will not change."]

In case the .cfg and/or the .ini files have been edited, the above command will update the POMS campaign accordingly.

Campaign details

To get info about existing POMS Campaigns there is the following command:

Project.py --show_campaigns

A typical output looks like this:

$ Project.py --show_campaigns 
{'view_active' : True,
 'view_analysis' : True,
 'view_inactive' : True,
 'view_mine' : True,
 'view_others' : None,
 'view_production' : None,
 'campaigns' : [

     { 'campaign_name' : 'test_vito_uBooNE_demo',
       'campaign_id' : 3866,
       'active' : True,
       'username' : vito,
       'creator_role' : 'analysis',
       'experiment' : 'uboone',
       'session_experiment' : 'uboone',
       'session_role' : 'analysis',
       'tags' : None,
       'stages' : [
            { 'stage_name' : 'overlay_training_trajcluster', 'stage_id' : 4945},
            { 'stage_name' : 'overlay_testing_trajcluster', 'stage_id' : 4946},
            { 'stage_name' : 'extbnb_trajcluster', 'stage_id' : 4948},
            { 'stage_name' : 'overlay_training_pandora', 'stage_id' : 4949},
            { 'stage_name' : 'overlay_testing_pandora', 'stage_id' : 4950},
            { 'stage_name' : 'bnb_pandora', 'stage_id' : 4951},
            { 'stage_name' : 'extbnb_pandora', 'stage_id' : 4952},
            { 'stage_name' : 'bnb_trajcluster', 'stage_id' : 4982},
            { 'stage_name' : 'test_stage', 'stage_id' : 4983}
        ]

    },
{'view_active' : True,
 'view_analysis' : True,
 'view_inactive' : None,
 'view_mine' : True,
 'view_others' : None,
 'view_production' : None,
 'campaigns' : [

     { 'campaign_name' : 'vito_UserAnalysis',
       'campaign_id' : 3880,
       'active' : True,
       'username' : vito,
       'creator_role' : 'analysis',
       'experiment' : 'uboone',
       'session_experiment' : 'uboone',
       'session_role' : 'analysis',
       'tags' : None,
       'stages' : [
            { 'stage_name' : 'myanalysis', 'stage_id' : 4994}
        ]

    }
] }

To get details of stages for a specific POMS Campaign the command is:

Project.py --show_campaign_stages --campaign vito_UserAnalysis
{'view_active' : True,
 'view_analysis' : True,
 'view_inactive' : None,
 'view_mine' : True,
 'view_others' : None,
 'view_production' : None,
 'campaign_id' : 3880,
 'experiment' : 'uboone',
 'session_experiment' : 'uboone',
 'session_role' : 'analysis',
 'username' : 'vito' ,
 'creator_role' : 'analysis',
 'campaign_stages' : [
     { 'stage_name' : 'myanalysis',
       'stage_id' : 4994,
       'stage_type' : 'regular',
       'completion_pct' : 95,
       'completion_type' :'complete',
       'created' : '2020-01-14T16:52:13',
       'cs_last_split' : None,
       'cs_split_dimensions' : None,
       'cs_split_type' : None,
       'dataset' : mydataset,
       'hold_experimenter_id' : None,
       'role_held_with' : None,
       'job_type_id' : 770,
       'login_setup_id' : 681,
       'merge_overrides' : False,
       'param_overrides' : [[u'--stage ', u'myanalysis']],
       'updated' : None,
       'updater' : None
     }
] }