Skip to content
Snippets Groups Projects
Commit 9fec4cf0 authored by alex's avatar alex
Browse files

Resolve RAP-165

Former-commit-id: c266d813 [formerly 4240981a]
Former-commit-id: 95fc5dfe
Former-commit-id: e8db6557
parent 511f8d59
Branches
Tags
No related merge requests found
Showing
with 63 additions and 65 deletions
image: lofareosc/prefactor-ci:latest image: lofareosc/prefactor3-cwl:latest
variables: variables:
TEST_DATASET_NAME: "L570745_uv_first10.MS.tar.xz" TEST_DATASET_NAME: "L570745_uv_first10.MS.tar.xz"
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip" PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
stages: stages:
- build_docker - download_data
- push_docker - test_prefactor
- validate_cwl_scripts - validate_cwl_scripts
- test_steps - test_steps
- integration_test - integration_test
...@@ -18,45 +18,52 @@ before_script: ...@@ -18,45 +18,52 @@ before_script:
after_script: after_script:
- echo "All done" - echo "All done"
build_docker: download_data:
image: docker:latest stage: download_data
stage: build_docker
only:
- tags
script: script:
- apk add git subversion git-lfs bash - mkdir data && cd data
- cd Docker - wget -q https://git.astron.nl/eosc/prefactor3-cwl/-/raw/master/test_data/$TEST_DATASET_NAME -O $TEST_DATASET_NAME && tar -xf $TEST_DATASET_NAME && rm -f $TEST_DATASET_NAME
- bash build_docker.sh - wget -q https://git.astron.nl/eosc/prefactor3-cwl/-/raw/master/test_data/example.h5 -O example.h5
- wget -q https://git.astron.nl/eosc/prefactor3-cwl/-/raw/master/test_data/A-Team_lowres.sourcedb -O A-Team_lowres.sourcedb
artifacts:
paths:
- data
push_docker_tags: test_prefactor:
image: docker:latest stage: test_prefactor
allow_failure: true needs: ["download_data"]
stage: push_docker
only:
- tags
script: script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - cd data
- docker tag lofareosc/prefactor-ci:latest $CI_REGISTRY/prefactor-ci:$CI_COMMIT_REF_NAME - ls -l
- docker push $CI_REGISTRY/prefactor-ci:$CI_COMMIT_REF_NAME
validate_scripts: validate_scripts:
stage: validate_cwl_scripts stage: validate_cwl_scripts
script: script:
- for file in `find . -name 'steps/*.cwl'`; do cwltool --validate $file; done - for file in `find . -name 'steps/*.cwl'`; do cwltool --validate $file; done
blsmooth:
stage: test_steps
allow_failure: true
needs: ["download_data"]
script:
- cwltool --no-container --preserve-environment LD_LIBRARY_PATH --preserve-environment PATH --preserve-environment PYTHONPATH steps/blsmooth.cwl test_jobs/blsmooth.json
find_skymodel_cal: find_skymodel_cal:
stage: test_steps stage: test_steps
allow_failure: true allow_failure: true
needs: ["download_data"]
script: script:
- cwltool --no-container --preserve-environment LD_LIBRARY_PATH --preserve-environment PATH --preserve-environment PYTHONPATH steps/find_skymodel_cal.cwl test_jobs/find_skymodel_cal.json - cwltool --no-container --preserve-environment LD_LIBRARY_PATH --preserve-environment PATH --preserve-environment PYTHONPATH steps/find_skymodel_cal.cwl test_jobs/find_skymodel_cal.json
blsmooth: check_ateam_separation:
stage: test_steps stage: test_steps
allow_failure: true allow_failure: true
needs: ["download_data"]
script: script:
- cwltool --no-container --preserve-environment LD_LIBRARY_PATH --preserve-environment PATH --preserve-environment PYTHONPATH steps/blsmooth.cwl test_jobs/blsmooth.json - cwltool --no-container --preserve-environment LD_LIBRARY_PATH --preserve-environment PATH --preserve-environment PYTHONPATH steps/check_ateam_separation.cwl test_jobs/check_ateam_separation.json
pol_align: prefactor_calibrator:
stage: integration_test stage: integration_test
needs: ["download_data"]
script: script:
- cwltool --no-container subworkflow/pol_align.cwl test_jobs/pol_align.json - cwltool --no-container workflows/HBA_calibrator.cwl test_jobs/HBA_calibrator.json
...@@ -4,8 +4,7 @@ $namespaces: ...@@ -4,8 +4,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: check_ateam_separation id: check_ateam_separation
baseCommand: baseCommand:
- python3 - Ateamclipper.py
- /usr/local/bin/Ateamclipper.py
inputs: inputs:
- id: msin - id: msin
type: type:
......
...@@ -5,8 +5,7 @@ $namespaces: ...@@ -5,8 +5,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: add_missing_stations id: add_missing_stations
baseCommand: baseCommand:
- python3 - add_missing_stations.py
- /usr/local/bin/add_missing_stations.py
inputs: inputs:
- default: output.h5 - default: output.h5
id: h5parm id: h5parm
......
...@@ -140,7 +140,6 @@ requirements: ...@@ -140,7 +140,6 @@ requirements:
mkdir -pv workdir mkdir -pv workdir
cp -r \$directories workdir/. && cd workdir cp -r \$directories workdir/. && cd workdir
concat=out.MS_[0-9*] concat=out.MS_[0-9*]
echo \$1 \$2 \$3 \$4 \$concat
aoflagger \$1 \$2 \$3 \$4 \$concat aoflagger \$1 \$2 \$3 \$4 \$concat
stdout: aoflag.log stdout: aoflag.log
......
...@@ -3,8 +3,7 @@ cwlVersion: v1.0 ...@@ -3,8 +3,7 @@ cwlVersion: v1.0
id: blsmooth id: blsmooth
label: BLsmooth label: BLsmooth
baseCommand: baseCommand:
- python3 - BLsmooth.py
- /usr/local/bin/BLsmooth.py
inputs: inputs:
- id: msin - id: msin
type: Directory type: Directory
......
...@@ -2,8 +2,7 @@ class: CommandLineTool ...@@ -2,8 +2,7 @@ class: CommandLineTool
cwlVersion: v1.0 cwlVersion: v1.0
id: check_ateam_separation id: check_ateam_separation
baseCommand: baseCommand:
- python3 - check_Ateam_separation.py
- /usr/local/bin/check_Ateam_separation.py
inputs: inputs:
- id: ms - id: ms
type: type:
......
...@@ -3,8 +3,7 @@ cwlVersion: v1.0 ...@@ -3,8 +3,7 @@ cwlVersion: v1.0
id: createRMh5parm id: createRMh5parm
label: createRMh5parm label: createRMh5parm
baseCommand: baseCommand:
- python3 - createRMh5parm.py
- /usr/local/bin/createRMh5parm.py
inputs: inputs:
- id: msin - id: msin
type: type:
......
...@@ -47,7 +47,7 @@ arguments: ...@@ -47,7 +47,7 @@ arguments:
valueFrom: d valueFrom: d
hints: hints:
- class: DockerRequirement - class: DockerRequirement
dockerPull: 'lofareosc/prefactor-ci:master' dockerPull: lofareosc/prefactor3-cwl
stdout: out_file
requirements: requirements:
- class: InlineJavascriptRequirement - class: InlineJavascriptRequirement
stdout: out_file
...@@ -5,8 +5,7 @@ $namespaces: ...@@ -5,8 +5,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: h5parm_pointingname id: h5parm_pointingname
baseCommand: baseCommand:
- python3 - h5parm_pointingname.py
- /usr/local/bin/h5parm_pointingname.py
inputs: inputs:
- format: 'lofar:#H5Parm' - format: 'lofar:#H5Parm'
id: h5parmFile id: h5parmFile
......
...@@ -4,8 +4,7 @@ $namespaces: ...@@ -4,8 +4,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: plot_Ateamclipper id: plot_Ateamclipper
baseCommand: baseCommand:
- python3 - plot_Ateamclipper.py
- /usr/local/bin/plot_Ateamclipper.py
inputs: inputs:
- id: clipper_output - id: clipper_output
type: File type: File
......
...@@ -5,8 +5,7 @@ $namespaces: ...@@ -5,8 +5,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: structure_function id: structure_function
baseCommand: baseCommand:
- python3 - getStructure_from_phases.py
- /usr/local/bin/getStructure_from_phases.py
inputs: inputs:
- format: 'lofar:#H5Parm' - format: 'lofar:#H5Parm'
id: h5parmFile id: h5parmFile
......
...@@ -4,8 +4,7 @@ $namespaces: ...@@ -4,8 +4,7 @@ $namespaces:
sbg: 'https://www.sevenbridges.com/' sbg: 'https://www.sevenbridges.com/'
id: transfer_solutions id: transfer_solutions
baseCommand: baseCommand:
- python3 - transfer_solutions.py
- /usr/local/bin/transfer_solutions.py
inputs: inputs:
- default: output.h5 - default: output.h5
id: h5parm id: h5parm
......
{
"msin" : [
{"class": "Directory", "path": "../data/L570745_SB000_uv_first10.MS"},
{"class": "Directory", "path": "../data/L570745_SB001_uv_first10.MS"},
{"class": "Directory", "path": "../data/L570745_SB002_uv_first10.MS"}
],
"raw_data": false,
"demix": false,
}
{ {
"msin": { "msin": {
"class": "Directory", "class": "Directory",
"path": "/data/L570745_SB003_uv_first10.MS" "path": "../data/L570745_SB003_uv_first10.MS"
}, },
"do_smooth": true "do_smooth": true
} }
{
"ms": {
"class": "Directory",
"path": "../data/L570745_SB001_uv_first10.MS"
}
}
{ {
"msin": { "msin": {
"class": "Directory", "class": "Directory",
"path": "/data/L570745_SB000_uv_first10.MS" "path": "../data/L570745_SB000_uv_first10.MS"
}, },
"skymodels": { "skymodels": {
"class": "Directory", "class": "Directory",
"path": "/data/skymodels" "path": "/usr/local/share/prefactor/skymodels"
} }
} }
{
"msin" : [
{"class": "Directory", "path": "/data/L570745_SB000_uv_first10.MS"},
{"class": "Directory", "path": "/data/L570745_SB001_uv_first10.MS"},
{"class": "Directory", "path": "/data/L570745_SB002_uv_first10.MS"}
],
"raw_data": false,
"demix": false,
"skymodels": {
"class": "Directory",
"path": "/data/skymodels"
},
"A-Team_sky_model": "/data/skymodels/Ateam_LBA_CC.skymodel"
}
...@@ -2,6 +2,6 @@ ...@@ -2,6 +2,6 @@
"input_h5parm": { "input_h5parm": {
"class": "File", "class": "File",
"format": "lofar:#H5Parm", "format": "lofar:#H5Parm",
"path": "/data/example.h5" "path": "../data/example.h5"
} }
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment