diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 38d10373b..d3e7e90df 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -4,6 +4,7 @@ on: pull_request: branches: - master + - develop jobs: @@ -34,3 +35,4 @@ jobs: run: | conda activate shapepipe python setup.py test + shapepipe_run -c example/config.ini diff --git a/example/config.ini b/example/config.ini index 915143b23..b6dc05e3d 100644 --- a/example/config.ini +++ b/example/config.ini @@ -42,7 +42,7 @@ NUMBERING_SCHEME = _0 ## ShapePipe job handling options [JOB] # BATCH_SIZE (optional) default is 1, i.e. run all jobs in serial -SMP_BATCH_SIZE = 3 +SMP_BATCH_SIZE = 2 # SMP_BACKEND (opional) options are loky, multiprocessing or threading, default is loky ; SMP_BACKEND = multiprocessing # TIMEOUT (optional) default is None, i.e. no timeout limit applied diff --git a/shapepipe/modules/galsim_shapes_v2_runner.py b/shapepipe/modules/galsim_shapes_v2_runner.py index a09864673..503178e1e 100644 --- a/shapepipe/modules/galsim_shapes_v2_runner.py +++ b/shapepipe/modules/galsim_shapes_v2_runner.py @@ -712,8 +712,10 @@ def process(tile_cat_path, tile_weight_path, gal_vignet_path, bkg_vignet_path, if skip_col: # Skip this object if marked, also if mark is nan - if tile_skip[i_tile] == skip_val \ - or (np.isnan(tile_skip[i_tile]) and np.isnan(skip_val)): + if ( + tile_skip[i_tile] == skip_val + or (np.isnan(tile_skip[i_tile]) and np.isnan(skip_val)) + ): continue count = count + 1 diff --git a/shapepipe/modules/python_example.py b/shapepipe/modules/python_example.py index 39e63d1d0..283c77dca 100644 --- a/shapepipe/modules/python_example.py +++ b/shapepipe/modules/python_example.py @@ -12,6 +12,20 @@ from numpy.random import randint from shapepipe.modules.module_decorator import module_runner +# Test import of key dependencies +import astropy +import galsim +import joblib +import mccd +import ngmix +import pandas +import pysap +import scipy +import sf_tools +import sip_tpv +import sqlitedict +import treecorr + class Dummy(object): diff --git a/shapepipe/utilities/canfar.py b/shapepipe/utilities/canfar.py index d5dcf712b..a5fca1849 100644 --- a/shapepipe/utilities/canfar.py +++ b/shapepipe/utilities/canfar.py @@ -9,7 +9,7 @@ """ import os -import sys +import sys try: import vos.commands as vosc @@ -92,6 +92,7 @@ def __call__(self, *args, **kwargs): raise vosError('Error in VOs command: {}' ''.format(self._command.__name__)) + def download(source, target, verbose=False): """Download file from vos.