From e2dfe9345c9900b2c60584c97d8441ab43074baf Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 27 Jan 2023 13:19:44 -0500 Subject: [PATCH 01/45] an update to handle uint16 data --- dataset/create_dataset.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dataset/create_dataset.py b/dataset/create_dataset.py index d49b8e98..60f05f41 100644 --- a/dataset/create_dataset.py +++ b/dataset/create_dataset.py @@ -179,6 +179,11 @@ def _get_tensor(self, query): out_shape=out_shape, window=from_bounds(*bounds, self.dr_ds.transform) ) + if dest.dtype == np.uint16: + dest = dest.astype(np.int32) + elif dest.dtype == np.uint32: + dest = dest.astype(np.int64) + tensor = torch.tensor(dest) return tensor @@ -285,7 +290,7 @@ def __getitem__(self, query: BoundingBox) -> Dict[str, Any]: ogr.Layer.Clip(self.mem_vec_ds.GetLayer(), mem_layer, out_layer) # Check that there is no curve geometry in the output patch: - self._check_curve(layer=out_layer) + # self._check_curve(layer=out_layer) sample = {"mask": out_mem_ds, "crs": self.crs, "bbox": query} From 217646908553a69c41a291830455eecb0ca4f661 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 27 Jan 2023 13:44:25 -0500 Subject: [PATCH 02/45] a fix for handling the OGR geometry type "GEOMETRYCOLLECTION" --- dataset/create_dataset.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dataset/create_dataset.py b/dataset/create_dataset.py index 60f05f41..63852714 100644 --- a/dataset/create_dataset.py +++ b/dataset/create_dataset.py @@ -240,10 +240,10 @@ def _check_curve(layer: ogr.Layer) -> None: feature = layer.GetNextFeature() while feature is not None: geom = feature.GetGeometryRef() - name = geom.GetGeometryName() + name_wkt = geom.ExportToWkt() # Approximate a curvature by a polygon geometry: - if name != "POLYGON" and name != "MULTIPOLYGON": + if 'curv' in name_wkt.lower(): linear_geom = geom.GetLinearGeometry() new_feature = ogr.Feature(feature_defn) new_feature.SetGeometryDirectly(linear_geom) @@ -290,7 +290,7 @@ def __getitem__(self, query: BoundingBox) -> Dict[str, Any]: ogr.Layer.Clip(self.mem_vec_ds.GetLayer(), mem_layer, out_layer) # Check that there is no curve geometry in the output patch: - # self._check_curve(layer=out_layer) + self._check_curve(layer=out_layer) sample = {"mask": out_mem_ds, "crs": self.crs, "bbox": query} From 5ccdf460c98eba532f533c7fc5842802bfb61271 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 2 Jun 2023 10:04:44 -0400 Subject: [PATCH 03/45] added to gha.yml: conda config --set channel_priority strict --- .github/workflows/github-actions-ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 1fa8c373..f9670441 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -20,6 +20,9 @@ jobs: run: | # $CONDA is an environment variable pointing to the root of the miniconda directory echo $CONDA/bin >> $GITHUB_PATH + - name: Set Conda Priority + run: | + conda config --set channel_priority strict - name: Install dependencies run: | conda env create --file environment.yml From bab5e078c785c89a4fd12f3ad93f6e41492c0180 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 2 Jun 2023 10:27:49 -0400 Subject: [PATCH 04/45] removed to gha.yml: conda config --set channel_priority strict --- .github/workflows/github-actions-ci.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index f9670441..1fa8c373 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -20,9 +20,6 @@ jobs: run: | # $CONDA is an environment variable pointing to the root of the miniconda directory echo $CONDA/bin >> $GITHUB_PATH - - name: Set Conda Priority - run: | - conda config --set channel_priority strict - name: Install dependencies run: | conda env create --file environment.yml From 292070dda9be7b7f7c701d487fd66612b76a710c Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Thu, 15 Jun 2023 09:55:54 -0400 Subject: [PATCH 05/45] removed commented rows --- .github/workflows/github-actions-ci.yml | 10 +++--- environment.yml | 44 +++++++++---------------- inference_segmentation.py | 8 ++--- tiling_segmentation.py | 2 +- 4 files changed, 23 insertions(+), 41 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 24f4bca0..1fa8c373 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -12,16 +12,14 @@ jobs: uses: actions/setup-python@v2 with: python-version: 3.9 + - name: Replace pytorch requirement with pytorch-cpu to speed up CI + run: | + sed -i -e 's/pytorch..*$/pytorch-cpu/g' environment.yml + sed -i -e 's/torchvision..*$/torchvision-cpu/g' environment.yml - name: Add conda to system path run: | # $CONDA is an environment variable pointing to the root of the miniconda directory echo $CONDA/bin >> $GITHUB_PATH - - name: Update Conda - run: | - conda update -n base -c defaults conda - - name: Set Conda Priority - run: | - conda config --set channel_priority strict - name: Install dependencies run: | conda env create --file environment.yml diff --git a/environment.yml b/environment.yml index d55bd909..48e434fc 100644 --- a/environment.yml +++ b/environment.yml @@ -3,38 +3,24 @@ channels: - pytorch - conda-forge dependencies: - - python>=3.10 - - pip>=23.1 + - coverage>=6.3.1 + - docker-py>=4.4.4 + - geopandas>=0.10.2 - hydra-core>=1.2.0 - - coverage>=6.5.0 - - geopandas>=0.12.1 - - rasterio>=1.3.3 - - ruamel_yaml>=0.15.80 - - pytorch==1.12.1 - - torchvision==0.13.1 + - pip + - pynvml>=11.0 + - pystac>=0.3.0 + - pytest>=7.1 + - python>=3.10 + - pytorch==1.12 + - rich>=11.1 + - ruamel_yaml>=0.15 + - scikit-image>=0.18 + - torchgeo>=0.3 + - torchvision>=0.12 - pip: - - pytorch-lightning>=1.7.7 - - segmentation-models-pytorch==0.3.0 - hydra-colorlog>=1.1.0 - hydra-optuna-sweeper>=1.1.0 - git+https://github.com/CosmiQ/solaris.git@0.5.0 - ttach>=0.0.3 - - mlflow>=2.0.1 - - pytest>=7.2.0 - - torchgeo==0.3.1 - - numpy>=1.23.5 - - shapely>=1.8.5 - - pystac>=1.6.1 - - omegaconf>=2.2.3 - - rich>=12.6.0 - - requests>=2.22.0 - - pandas>=1.5.2 - - affine>=2.3.1 - - tqdm>=4.64.1 - - pyproj>=3.4.0 - - fiona>=1.8.22 - - scipy>=1.9.3 - - scikit-image>=0.19.3 - - pillow>=9.2.0 - - kornia>=0.6.8 - - scikit-learn>=1.1.3 \ No newline at end of file + - mlflow>=1.2 # causes env solving to hang if not with pip diff --git a/inference_segmentation.py b/inference_segmentation.py index e7b3a746..55153d5a 100644 --- a/inference_segmentation.py +++ b/inference_segmentation.py @@ -171,10 +171,8 @@ def segmentation(param, fp = np.memmap(tp_mem, dtype='float16', mode='w+', shape=(tf_len, h_padded, w_padded, num_classes)) img_gen = gen_img_samples(src=input_image, patch_list=patch_list, chunk_size=chunk_size) single_class_mode = False if num_classes > 1 else True - for sub_image, h_idxs, w_idxs, hann_win in tqdm( - img_gen, position=0, leave=True, desc='Inferring on patches', - total=len(patch_list) - ): + for sub_image, h_idxs, w_idxs, hann_win in tqdm(img_gen, position=0, leave=True, + desc=f'Inferring on patches'): hann_win = np.expand_dims(hann_win, -1) image_metadata = add_metadata_from_raster_to_sample(sat_img_arr=sub_image, raster_handle=input_image, @@ -287,7 +285,7 @@ def override_model_params_from_checkpoint( if model_ckpt != params.model or classes_ckpt != classes or bands_ckpt != bands \ or clip_limit != clip_limit_ckpt: - logging.info("\nParameters from checkpoint will override inputted parameters." + logging.info(f"\nParameters from checkpoint will override inputted parameters." f"\n\t\t\t Inputted | Overriden" f"\nModel:\t\t {params.model} | {model_ckpt}" f"\nInput bands:\t\t{bands} | {bands_ckpt}" diff --git a/tiling_segmentation.py b/tiling_segmentation.py index 2d1ef7fe..76df5d05 100644 --- a/tiling_segmentation.py +++ b/tiling_segmentation.py @@ -741,7 +741,7 @@ def main(cfg: DictConfig) -> None: # TODO: use mp.Manager() to modify aoi.tiling_pairs_list from within tiling_per_aoi tiler.src_aoi_list = [] for tiled_aoi, rs_tiler_paths, vec_tiler_paths in tqdm( - tilers, desc="Updating AOIs' information about their patches paths"): + tilers, desc=f"Updating AOIs' information about their patches paths"): tiled_aoi.patches_pairs_list = [(rs_ptch, gt_ptch) for rs_ptch, gt_ptch in zip(rs_tiler_paths, vec_tiler_paths)] tiler.src_aoi_list.append(tiled_aoi) From e5be7343295fcb5df5084091b1d098158c274a10 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Thu, 15 Jun 2023 10:01:35 -0400 Subject: [PATCH 06/45] fix gh actions --- .github/workflows/github-actions-ci.yml | 10 +++--- environment.yml | 44 ++++++++++++++++--------- 2 files changed, 35 insertions(+), 19 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 1fa8c373..24f4bca0 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -12,14 +12,16 @@ jobs: uses: actions/setup-python@v2 with: python-version: 3.9 - - name: Replace pytorch requirement with pytorch-cpu to speed up CI - run: | - sed -i -e 's/pytorch..*$/pytorch-cpu/g' environment.yml - sed -i -e 's/torchvision..*$/torchvision-cpu/g' environment.yml - name: Add conda to system path run: | # $CONDA is an environment variable pointing to the root of the miniconda directory echo $CONDA/bin >> $GITHUB_PATH + - name: Update Conda + run: | + conda update -n base -c defaults conda + - name: Set Conda Priority + run: | + conda config --set channel_priority strict - name: Install dependencies run: | conda env create --file environment.yml diff --git a/environment.yml b/environment.yml index 48e434fc..815e4bbf 100644 --- a/environment.yml +++ b/environment.yml @@ -3,24 +3,38 @@ channels: - pytorch - conda-forge dependencies: - - coverage>=6.3.1 - - docker-py>=4.4.4 - - geopandas>=0.10.2 - - hydra-core>=1.2.0 - - pip - - pynvml>=11.0 - - pystac>=0.3.0 - - pytest>=7.1 - python>=3.10 - - pytorch==1.12 - - rich>=11.1 - - ruamel_yaml>=0.15 - - scikit-image>=0.18 - - torchgeo>=0.3 - - torchvision>=0.12 + - pip>=23.1 + - hydra-core>=1.2.0 + - coverage>=6.5.0 + - geopandas>=0.12.1 + - rasterio>=1.3.3 + - ruamel_yaml>=0.15.80 + - pytorch==1.12.1 + - torchvision==0.13.1 - pip: + - pytorch-lightning>=1.7.7 + - segmentation-models-pytorch==0.3.0 - hydra-colorlog>=1.1.0 - hydra-optuna-sweeper>=1.1.0 - git+https://github.com/CosmiQ/solaris.git@0.5.0 - ttach>=0.0.3 - - mlflow>=1.2 # causes env solving to hang if not with pip + - mlflow>=2.0.1 + - pytest>=7.2.0 + - torchgeo==0.3.1 + - numpy>=1.23.5 + - shapely>=1.8.5 + - pystac>=1.6.1 + - omegaconf>=2.2.3 + - rich>=12.6.0 + - requests>=2.22.0 + - pandas>=1.5.2 + - affine>=2.3.1 + - tqdm>=4.64.1 + - pyproj>=3.4.0 + - fiona>=1.8.22 + - scipy>=1.9.3 + - scikit-image>=0.19.3 + - pillow>=9.2.0 + - kornia>=0.6.8 + - scikit-learn>=1.1.3 From 9f828f4f49e7191d34e8325f8f4833a007d53982 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Tue, 4 Jul 2023 15:27:05 -0400 Subject: [PATCH 07/45] fix for github CI --- environment.yml | 2 +- inference_segmentation.py | 6 ++++-- tiling_segmentation.py | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/environment.yml b/environment.yml index 815e4bbf..d55bd909 100644 --- a/environment.yml +++ b/environment.yml @@ -37,4 +37,4 @@ dependencies: - scikit-image>=0.19.3 - pillow>=9.2.0 - kornia>=0.6.8 - - scikit-learn>=1.1.3 + - scikit-learn>=1.1.3 \ No newline at end of file diff --git a/inference_segmentation.py b/inference_segmentation.py index 55153d5a..4ffcaa10 100644 --- a/inference_segmentation.py +++ b/inference_segmentation.py @@ -171,8 +171,10 @@ def segmentation(param, fp = np.memmap(tp_mem, dtype='float16', mode='w+', shape=(tf_len, h_padded, w_padded, num_classes)) img_gen = gen_img_samples(src=input_image, patch_list=patch_list, chunk_size=chunk_size) single_class_mode = False if num_classes > 1 else True - for sub_image, h_idxs, w_idxs, hann_win in tqdm(img_gen, position=0, leave=True, - desc=f'Inferring on patches'): + for sub_image, h_idxs, w_idxs, hann_win in tqdm( + img_gen, position=0, leave=True, desc='Inferring on patches', + total=len(patch_list) + ): hann_win = np.expand_dims(hann_win, -1) image_metadata = add_metadata_from_raster_to_sample(sat_img_arr=sub_image, raster_handle=input_image, diff --git a/tiling_segmentation.py b/tiling_segmentation.py index 76df5d05..2d1ef7fe 100644 --- a/tiling_segmentation.py +++ b/tiling_segmentation.py @@ -741,7 +741,7 @@ def main(cfg: DictConfig) -> None: # TODO: use mp.Manager() to modify aoi.tiling_pairs_list from within tiling_per_aoi tiler.src_aoi_list = [] for tiled_aoi, rs_tiler_paths, vec_tiler_paths in tqdm( - tilers, desc=f"Updating AOIs' information about their patches paths"): + tilers, desc="Updating AOIs' information about their patches paths"): tiled_aoi.patches_pairs_list = [(rs_ptch, gt_ptch) for rs_ptch, gt_ptch in zip(rs_tiler_paths, vec_tiler_paths)] tiler.src_aoi_list.append(tiled_aoi) From 4a0cfe14405dbd8b092ae8e97189fbd7b085b39c Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 11:31:50 -0400 Subject: [PATCH 08/45] switching the default library path from the OS's to the Conda packages' --- Dockerfile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Dockerfile b/Dockerfile index 769124f3..02daa4ad 100644 --- a/Dockerfile +++ b/Dockerfile @@ -27,6 +27,8 @@ RUN wget https://github.com/conda-forge/miniforge/releases/latest/download/Mamba apt-get clean && \ rm -rf /var/lib/apt/lists/* +ENV LD_LIBRARY_PATH $CONDA_DIR/lib:$LD_LIBRARY_PATH + # Create the user RUN useradd --create-home -s /bin/bash --no-user-group -u $USERID $USERNAME && \ chown $USERNAME $CONDA_DIR -R && \ From 4f847a142fdadba9e8e73814e7df1d6b1d182645 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 11:35:08 -0400 Subject: [PATCH 09/45] switching the default library path from the OS's to the Conda packages' --- inference_segmentation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inference_segmentation.py b/inference_segmentation.py index 4ffcaa10..e7b3a746 100644 --- a/inference_segmentation.py +++ b/inference_segmentation.py @@ -287,7 +287,7 @@ def override_model_params_from_checkpoint( if model_ckpt != params.model or classes_ckpt != classes or bands_ckpt != bands \ or clip_limit != clip_limit_ckpt: - logging.info(f"\nParameters from checkpoint will override inputted parameters." + logging.info("\nParameters from checkpoint will override inputted parameters." f"\n\t\t\t Inputted | Overriden" f"\nModel:\t\t {params.model} | {model_ckpt}" f"\nInput bands:\t\t{bands} | {bands_ckpt}" From f008127286aae685f582079f5b4e36b67e21d46b Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 13:14:18 -0400 Subject: [PATCH 10/45] changed the docker image for the tests --- .github/workflows/github-actions-ci.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 8eff2e0c..8e1eae1f 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -3,10 +3,9 @@ on: [push, pull_request] jobs: unit-tests: runs-on: ubuntu-latest - # runs within your Docker container container: - image: docker://geobaserepo/gdl-cuda11:latest + image: docker://geobaserepo/gdl-cuda11:v2.8.1 options: --user root # checkout your code from your repository # and runs pytest in your pipenv environment From 333eb3317d806d656901e4c54f92cd2020a1a66b Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 13:55:50 -0400 Subject: [PATCH 11/45] clean space before image pulling --- .github/workflows/github-actions-ci.yml | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 8e1eae1f..396f8955 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -1,6 +1,26 @@ name: GitHub Actions Unit Tests on: [push, pull_request] jobs: + free-disk-space: + runs-on: ubuntu-latest + steps: + + - name: Free Disk Space (Ubuntu) + uses: jlumbroso/free-disk-space@main + with: + # this might remove tools that are actually needed, + # if set to "true" but frees about 6 GB + tool-cache: false + + # all of these default to true, but feel free to set to + # "false" if necessary for your workflow + android: true + dotnet: true + haskell: true + large-packages: true + docker-images: true + swap-storage: true + unit-tests: runs-on: ubuntu-latest # runs within your Docker container From a0d51bb3affaaee509780eefe100716cc865af6e Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 14:15:34 -0400 Subject: [PATCH 12/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 36 ++++++++++++++----------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 396f8955..edb09777 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -1,10 +1,16 @@ name: GitHub Actions Unit Tests on: [push, pull_request] jobs: - free-disk-space: + unit-tests: runs-on: ubuntu-latest - steps: + # runs within your Docker container + container: + image: docker://geobaserepo/gdl-cuda11:v2.8.1 + options: --user root + # checkout your code from your repository + # and runs pytest in your pipenv environment + steps: - name: Free Disk Space (Ubuntu) uses: jlumbroso/free-disk-space@main with: @@ -21,19 +27,17 @@ jobs: docker-images: true swap-storage: true - unit-tests: - runs-on: ubuntu-latest - # runs within your Docker container - container: - image: docker://geobaserepo/gdl-cuda11:v2.8.1 - options: --user root - # checkout your code from your repository - # and runs pytest in your pipenv environment - steps: - - name: Install pipenv - run: | - pip install pipenv + - name: Pull the Docker Image + run: docker pull docker://geobaserepo/gdl-cuda11:v2.8.1 + - uses: actions/checkout@v2 - - name: Test with pytest + - name: Run pytest run: | - pipenv run pytest tests/ \ No newline at end of file + docker run -v "$(pwd)":geo-deep-learning/tests gdl-cuda11:v2.8.1 pytest +# - name: Install pipenv +# run: | +# pip install pipenv +# +# - name: Test with pytest +# run: | +# pipenv run pytest tests/ \ No newline at end of file From 5283f624741f9ea0fa8635b5df8a745001679dc4 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 14:16:25 -0400 Subject: [PATCH 13/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index edb09777..43593666 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -5,9 +5,9 @@ jobs: runs-on: ubuntu-latest # runs within your Docker container - container: - image: docker://geobaserepo/gdl-cuda11:v2.8.1 - options: --user root +# container: +# image: docker://geobaserepo/gdl-cuda11:v2.8.1 +# options: --user root # checkout your code from your repository # and runs pytest in your pipenv environment steps: From 5faf819fdd2b96a374885b3e10afc9e13d2cb4ff Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 14:23:11 -0400 Subject: [PATCH 14/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 34 ++++++++++++------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 43593666..13210ce2 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -11,29 +11,29 @@ jobs: # checkout your code from your repository # and runs pytest in your pipenv environment steps: - - name: Free Disk Space (Ubuntu) - uses: jlumbroso/free-disk-space@main - with: - # this might remove tools that are actually needed, - # if set to "true" but frees about 6 GB - tool-cache: false - - # all of these default to true, but feel free to set to - # "false" if necessary for your workflow - android: true - dotnet: true - haskell: true - large-packages: true - docker-images: true - swap-storage: true +# - name: Free Disk Space (Ubuntu) +# uses: jlumbroso/free-disk-space@main +# with: +# # this might remove tools that are actually needed, +# # if set to "true" but frees about 6 GB +# tool-cache: false +# +# # all of these default to true, but feel free to set to +# # "false" if necessary for your workflow +# android: true +# dotnet: true +# haskell: true +# large-packages: true +# docker-images: true +# swap-storage: true - name: Pull the Docker Image - run: docker pull docker://geobaserepo/gdl-cuda11:v2.8.1 + run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - uses: actions/checkout@v2 - name: Run pytest run: | - docker run -v "$(pwd)":geo-deep-learning/tests gdl-cuda11:v2.8.1 pytest + docker run -v "$(pwd)":geo-deep-learning/tests geobaserepo/gdl-cuda11:v2.8.1 pytest # - name: Install pipenv # run: | # pip install pipenv From 9aaf18195ae991a03c6f0363ea64de3e3dfa7db4 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 14:24:55 -0400 Subject: [PATCH 15/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 30 ++++++++++++------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 13210ce2..c993e968 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -11,21 +11,21 @@ jobs: # checkout your code from your repository # and runs pytest in your pipenv environment steps: -# - name: Free Disk Space (Ubuntu) -# uses: jlumbroso/free-disk-space@main -# with: -# # this might remove tools that are actually needed, -# # if set to "true" but frees about 6 GB -# tool-cache: false -# -# # all of these default to true, but feel free to set to -# # "false" if necessary for your workflow -# android: true -# dotnet: true -# haskell: true -# large-packages: true -# docker-images: true -# swap-storage: true + - name: Free Disk Space (Ubuntu) + uses: jlumbroso/free-disk-space@main + with: + # this might remove tools that are actually needed, + # if set to "true" but frees about 6 GB + tool-cache: false + + # all of these default to true, but feel free to set to + # "false" if necessary for your workflow + android: true + dotnet: true + haskell: true + large-packages: true + docker-images: true + swap-storage: true - name: Pull the Docker Image run: docker pull geobaserepo/gdl-cuda11:v2.8.1 From 4fd8de8e218625b47d8d4b33b99ba305617d30d6 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:06:07 -0400 Subject: [PATCH 16/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index c993e968..9672493c 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -33,7 +33,7 @@ jobs: - uses: actions/checkout@v2 - name: Run pytest run: | - docker run -v "$(pwd)":geo-deep-learning/tests geobaserepo/gdl-cuda11:v2.8.1 pytest + docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest tests/ # - name: Install pipenv # run: | # pip install pipenv From 4c8897c4be2cb83df1a7664e5f6ba74d5daae5fe Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:14:24 -0400 Subject: [PATCH 17/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 9672493c..39bf6db6 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -33,7 +33,7 @@ jobs: - uses: actions/checkout@v2 - name: Run pytest run: | - docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest tests/ + docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest geo-deep-learning/tests/ # - name: Install pipenv # run: | # pip install pipenv From b60c0c3b9a59dc1c18228052beb11ae488a9ba4f Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:27:45 -0400 Subject: [PATCH 18/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 39bf6db6..3d1407f7 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -30,10 +30,13 @@ jobs: - name: Pull the Docker Image run: docker pull geobaserepo/gdl-cuda11:v2.8.1 + - name: Checkout repository - uses: actions/checkout@v2 + - name: Run pytest run: | - docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest geo-deep-learning/tests/ +# docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest geo-deep-learning/tests/ + docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" # - name: Install pipenv # run: | # pip install pipenv From e22acf53fc82323c7a9751d5df36dfe03fcc6410 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:28:42 -0400 Subject: [PATCH 19/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 3d1407f7..04db901b 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -31,7 +31,7 @@ jobs: run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - name: Checkout repository - - uses: actions/checkout@v2 + uses: actions/checkout@v2 - name: Run pytest run: | From e218bdbb81f0a604e2c6dfa3e4607b9516b11863 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:29:33 -0400 Subject: [PATCH 20/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 04db901b..38fb7d6c 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -30,8 +30,7 @@ jobs: - name: Pull the Docker Image run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - - name: Checkout repository - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - name: Run pytest run: | From 3a3d515b12c390fd1b99d5d3ec4d4e3805bc4cb8 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:31:28 -0400 Subject: [PATCH 21/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 38fb7d6c..81556b2a 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -31,15 +31,6 @@ jobs: run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - uses: actions/checkout@v2 - - name: Run pytest run: | -# docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 pytest geo-deep-learning/tests/ - docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" -# - name: Install pipenv -# run: | -# pip install pipenv -# -# - name: Test with pytest -# run: | -# pipenv run pytest tests/ \ No newline at end of file + docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" \ No newline at end of file From 73014099bba67ba6a9034c7253d6e70242c4db95 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 16:42:11 -0400 Subject: [PATCH 22/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 81556b2a..24ec7b29 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -31,6 +31,11 @@ jobs: run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - uses: actions/checkout@v2 + + - name: Set Permissions + run: | + sudo chown -R $USER:$USER . + - name: Run pytest run: | docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" \ No newline at end of file From 96eca031a9e50caac3f2b17566130290034aeb24 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Fri, 29 Sep 2023 18:00:16 -0400 Subject: [PATCH 23/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 24ec7b29..bd9944cb 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -35,7 +35,7 @@ jobs: - name: Set Permissions run: | sudo chown -R $USER:$USER . - + - name: Run pytest run: | - docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" \ No newline at end of file + sudo docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" \ No newline at end of file From cd51b45ec386784ddcdc1b54001ce5829c109783 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 13:52:28 -0400 Subject: [PATCH 24/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 69 ++++++++++++++++++------- 1 file changed, 51 insertions(+), 18 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index bd9944cb..90b467af 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -1,16 +1,15 @@ name: GitHub Actions Unit Tests on: [push, pull_request] jobs: - unit-tests: - runs-on: ubuntu-latest - - # runs within your Docker container -# container: -# image: docker://geobaserepo/gdl-cuda11:v2.8.1 -# options: --user root - # checkout your code from your repository - # and runs pytest in your pipenv environment - steps: + jobs: + clean-and-deploy-env: + name: Clean the space + runs-on: ubuntu-latest + env: + CONDA_DIR: "/opt/conda" + USERNAME: "gdl_user" + USERID: "1000" + steps: - name: Free Disk Space (Ubuntu) uses: jlumbroso/free-disk-space@main with: @@ -27,15 +26,49 @@ jobs: docker-images: true swap-storage: true - - name: Pull the Docker Image - run: docker pull geobaserepo/gdl-cuda11:v2.8.1 - - - uses: actions/checkout@v2 + - name: Update the environment + run: | + apt-get update \ + && apt-get install -y --no-install-recommends git wget unzip bzip2 build-essential sudo \ + && apt-key del 7fa2af80 \ + && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb \ + && sudo dpkg -i cuda-keyring_1.0-1_all.deb \ + && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004-keyring.gpg \ + && sudo mv cuda-ubuntu2004-keyring.gpg /usr/share/keyrings/cuda-archive-keyring.gpg \ + && rm -f cuda-keyring_1.0-1_all.deb && rm -f /etc/apt/sources.list.d/cuda.list - - name: Set Permissions + - name: Install Mamba run: | - sudo chown -R $USER:$USER . + export PATH="$CONDA_DIR:$PATH" + PATH $CONDA_DIR/bin:$PATH + wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ + /bin/bash /tmp/mamba.sh -b -p $CONDA_DIR && \ + rm -rf /tmp/* && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists/* + export LD_LIBRARY_PATH="$CONDA_DIR:LD_LIBRARY_PATH" - - name: Run pytest + - name: Checkout the repo + uses: actions/checkout@v2 + + - name: Test with pytest run: | - sudo docker run -v "$(pwd)":/gdl geobaserepo/gdl-cuda11:v2.8.1 bash -c "cd /gdl && pytest tests/" \ No newline at end of file + pytest tests/ + +# unit-tests: +# runs-on: ubuntu-latest +# needs: clean-and-deploy +# # runs within your Docker container +# container: +# image: geobaserepo/gdl-cuda11:v2.8.1 +# options: --user root +# # checkout your code from your repository +# # and runs pytest in your pipenv environment +# steps: +# - name: Install pipenv +# run: | +# pip install pipenv +# - uses: actions/checkout@v2 +# - name: Test with pytest +# run: | +# pipenv run pytest tests/ \ No newline at end of file From 506658bff9e4b16c8f70e52e051b5696dce2b092 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 13:55:09 -0400 Subject: [PATCH 25/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 90b467af..8881a97a 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -1,15 +1,13 @@ name: GitHub Actions Unit Tests on: [push, pull_request] jobs: - jobs: - clean-and-deploy-env: - name: Clean the space - runs-on: ubuntu-latest - env: - CONDA_DIR: "/opt/conda" - USERNAME: "gdl_user" - USERID: "1000" - steps: + clean-and-deploy-env: + runs-on: ubuntu-latest + env: + CONDA_DIR: "/opt/conda" + USERNAME: "gdl_user" + USERID: "1000" + steps: - name: Free Disk Space (Ubuntu) uses: jlumbroso/free-disk-space@main with: From ce7089e88aa29e23ee8c8627f1b15adf6b4c7c74 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:01:38 -0400 Subject: [PATCH 26/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 8881a97a..6cbde767 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -26,24 +26,24 @@ jobs: - name: Update the environment run: | - apt-get update \ - && apt-get install -y --no-install-recommends git wget unzip bzip2 build-essential sudo \ + sudo apt-get update \ + && sudo apt-get install -y --no-install-recommends git wget unzip bzip2 build-essential sudo \ && apt-key del 7fa2af80 \ - && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb \ + && sudo wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb \ && sudo dpkg -i cuda-keyring_1.0-1_all.deb \ - && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004-keyring.gpg \ + && sudo wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004-keyring.gpg \ && sudo mv cuda-ubuntu2004-keyring.gpg /usr/share/keyrings/cuda-archive-keyring.gpg \ - && rm -f cuda-keyring_1.0-1_all.deb && rm -f /etc/apt/sources.list.d/cuda.list + && sudo rm -f cuda-keyring_1.0-1_all.deb && sudo rm -f /etc/apt/sources.list.d/cuda.list - name: Install Mamba run: | export PATH="$CONDA_DIR:$PATH" PATH $CONDA_DIR/bin:$PATH - wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ + sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ /bin/bash /tmp/mamba.sh -b -p $CONDA_DIR && \ - rm -rf /tmp/* && \ - apt-get clean && \ - rm -rf /var/lib/apt/lists/* + sudo rm -rf /tmp/* && \ + sudo apt-get clean && \ + sudo rm -rf /var/lib/apt/lists/* export LD_LIBRARY_PATH="$CONDA_DIR:LD_LIBRARY_PATH" - name: Checkout the repo From 923ef2d0d500a29d8d435f1ed017bff28685aa59 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:07:11 -0400 Subject: [PATCH 27/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 6cbde767..612b0487 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -18,17 +18,17 @@ jobs: # all of these default to true, but feel free to set to # "false" if necessary for your workflow android: true - dotnet: true - haskell: true - large-packages: true - docker-images: true - swap-storage: true + dotnet: false + haskell: false + large-packages: false + docker-images: false + swap-storage: false - name: Update the environment run: | sudo apt-get update \ && sudo apt-get install -y --no-install-recommends git wget unzip bzip2 build-essential sudo \ - && apt-key del 7fa2af80 \ + && sudo apt-key del 7fa2af80 \ && sudo wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-keyring_1.0-1_all.deb \ && sudo dpkg -i cuda-keyring_1.0-1_all.deb \ && sudo wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004-keyring.gpg \ From 3cfdd7fe67b95d4227d1cfaba5e2889028a81a8a Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:09:27 -0400 Subject: [PATCH 28/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 612b0487..8ae9439c 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -37,14 +37,14 @@ jobs: - name: Install Mamba run: | - export PATH="$CONDA_DIR:$PATH" + echo "export PATH=$CONDA_DIR:$PATH" PATH $CONDA_DIR/bin:$PATH sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ /bin/bash /tmp/mamba.sh -b -p $CONDA_DIR && \ sudo rm -rf /tmp/* && \ sudo apt-get clean && \ sudo rm -rf /var/lib/apt/lists/* - export LD_LIBRARY_PATH="$CONDA_DIR:LD_LIBRARY_PATH" + echo "export LD_LIBRARY_PATH=$CONDA_DIR:LD_LIBRARY_PATH" - name: Checkout the repo uses: actions/checkout@v2 From a297fa687b0153d9fd465326229793cc532bae9b Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:12:29 -0400 Subject: [PATCH 29/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 8ae9439c..f2af22f9 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -38,7 +38,6 @@ jobs: - name: Install Mamba run: | echo "export PATH=$CONDA_DIR:$PATH" - PATH $CONDA_DIR/bin:$PATH sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ /bin/bash /tmp/mamba.sh -b -p $CONDA_DIR && \ sudo rm -rf /tmp/* && \ From b23488ff08354b803e54a297e6a83a9a8d083ef1 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:15:36 -0400 Subject: [PATCH 30/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index f2af22f9..a9d4f8a0 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -48,9 +48,14 @@ jobs: - name: Checkout the repo uses: actions/checkout@v2 + - name: Install pyenv + run: | + pip install pipenv + - uses: actions/checkout@v2 - name: Test with pytest run: | - pytest tests/ + pipenv run pytest tests/ + # unit-tests: # runs-on: ubuntu-latest From ecab55cc9403d1d476d87632ac96230a0efc62dc Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:15:46 -0400 Subject: [PATCH 31/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index a9d4f8a0..28a764bc 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -45,9 +45,6 @@ jobs: sudo rm -rf /var/lib/apt/lists/* echo "export LD_LIBRARY_PATH=$CONDA_DIR:LD_LIBRARY_PATH" - - name: Checkout the repo - uses: actions/checkout@v2 - - name: Install pyenv run: | pip install pipenv From d9ae5a4505af25a1b503cddaefe0d7f6c1991373 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:18:38 -0400 Subject: [PATCH 32/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 28a764bc..d7018f1c 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -48,6 +48,7 @@ jobs: - name: Install pyenv run: | pip install pipenv + pip install pytest - uses: actions/checkout@v2 - name: Test with pytest run: | From 4efccf8848d0323fcbaf24f105d561c5c078fed9 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:23:09 -0400 Subject: [PATCH 33/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index d7018f1c..9f04c381 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -50,6 +50,12 @@ jobs: pip install pipenv pip install pytest - uses: actions/checkout@v2 + + - name: Install dependencies + run: | + sudo mamba env create -f environment.yml \ + echo "export PATH=$CONDA_DIR/envs/geo_deep_env/bin:$PATH" + - name: Test with pytest run: | pipenv run pytest tests/ From 61e78af78e0e2cf747c2388ea9b7ad762c5b8908 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:35:27 -0400 Subject: [PATCH 34/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 9f04c381..8d7d9912 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -35,6 +35,19 @@ jobs: && sudo mv cuda-ubuntu2004-keyring.gpg /usr/share/keyrings/cuda-archive-keyring.gpg \ && sudo rm -f cuda-keyring_1.0-1_all.deb && sudo rm -f /etc/apt/sources.list.d/cuda.list + - name: Set system variables + run: | + echo 'export PATH=$PATH:$CONDA_DIR' >> $GITHUB_ENV + echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$CONDA_DIR/lib' >> $GITHUB_ENV + echo '::add-path::$CONDA_DIR' >> $GITHUB_ENV + echo '::set-env name=LD_LIBRARY_PATH::$CONDA_DIR/lib' >> $GITHUB_ENV + source $GITHUB_ENV + + - name: Check if Custom Paths are Added + run: | + echo $PATH + echo $LD_LIBRARY_PATH + - name: Install Mamba run: | echo "export PATH=$CONDA_DIR:$PATH" @@ -43,7 +56,7 @@ jobs: sudo rm -rf /tmp/* && \ sudo apt-get clean && \ sudo rm -rf /var/lib/apt/lists/* - echo "export LD_LIBRARY_PATH=$CONDA_DIR:LD_LIBRARY_PATH" + - name: Install pyenv run: | From 2e0d42a8284455d5143bbe598c6cf5863ab34800 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:40:40 -0400 Subject: [PATCH 35/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 8d7d9912..01d47506 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -39,8 +39,6 @@ jobs: run: | echo 'export PATH=$PATH:$CONDA_DIR' >> $GITHUB_ENV echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$CONDA_DIR/lib' >> $GITHUB_ENV - echo '::add-path::$CONDA_DIR' >> $GITHUB_ENV - echo '::set-env name=LD_LIBRARY_PATH::$CONDA_DIR/lib' >> $GITHUB_ENV source $GITHUB_ENV - name: Check if Custom Paths are Added From 68fee966f12286a5c66e4628e63b064d8945e218 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:51:25 -0400 Subject: [PATCH 36/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 01d47506..32960d53 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -7,6 +7,7 @@ jobs: CONDA_DIR: "/opt/conda" USERNAME: "gdl_user" USERID: "1000" + LD_LIBRARY_PATH: "/opt/conda/lib" steps: - name: Free Disk Space (Ubuntu) uses: jlumbroso/free-disk-space@main @@ -37,9 +38,7 @@ jobs: - name: Set system variables run: | - echo 'export PATH=$PATH:$CONDA_DIR' >> $GITHUB_ENV - echo 'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$CONDA_DIR/lib' >> $GITHUB_ENV - source $GITHUB_ENV + echo '$CONDA_DIR' >> $GITHUB_PATH - name: Check if Custom Paths are Added run: | @@ -48,9 +47,9 @@ jobs: - name: Install Mamba run: | - echo "export PATH=$CONDA_DIR:$PATH" +# echo "export PATH=$CONDA_DIR:$PATH" sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ - /bin/bash /tmp/mamba.sh -b -p $CONDA_DIR && \ + /bin/bash /tmp/mamba.sh -b -p /opt/conda && \ sudo rm -rf /tmp/* && \ sudo apt-get clean && \ sudo rm -rf /var/lib/apt/lists/* From d1281020523135fa6e3e080110d35c0531dcc004 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:53:09 -0400 Subject: [PATCH 37/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 32960d53..781e1365 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -42,12 +42,11 @@ jobs: - name: Check if Custom Paths are Added run: | - echo $PATH - echo $LD_LIBRARY_PATH + echo "$PATH" + echo "$LD_LIBRARY_PATH" - name: Install Mamba run: | -# echo "export PATH=$CONDA_DIR:$PATH" sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ /bin/bash /tmp/mamba.sh -b -p /opt/conda && \ sudo rm -rf /tmp/* && \ From 6ebbec1bfaa5725556b93d7445372aa4d53c9aee Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 14:55:30 -0400 Subject: [PATCH 38/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 781e1365..055b4d17 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -38,7 +38,7 @@ jobs: - name: Set system variables run: | - echo '$CONDA_DIR' >> $GITHUB_PATH + echo '/opt/conda' >> $GITHUB_PATH - name: Check if Custom Paths are Added run: | From 09eb39db3eab6f0774265a35dcdac19aa592b7a2 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:02:13 -0400 Subject: [PATCH 39/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 055b4d17..6c10139f 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -39,6 +39,7 @@ jobs: - name: Set system variables run: | echo '/opt/conda' >> $GITHUB_PATH + source $GITHUB_PATH - name: Check if Custom Paths are Added run: | @@ -62,8 +63,9 @@ jobs: - name: Install dependencies run: | - sudo mamba env create -f environment.yml \ - echo "export PATH=$CONDA_DIR/envs/geo_deep_env/bin:$PATH" + sudo /opt/conda/mamba env create -f environment.yml \ + echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH + source $GITHUB_PATH - name: Test with pytest run: | From c85006f8c31201366775fc885ed6f3a95c9f039b Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:04:14 -0400 Subject: [PATCH 40/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 6c10139f..f5b583d9 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -39,7 +39,7 @@ jobs: - name: Set system variables run: | echo '/opt/conda' >> $GITHUB_PATH - source $GITHUB_PATH +# source $GITHUB_PATH - name: Check if Custom Paths are Added run: | From a3ce6ae610d74b7b1d56555005b7fb7f4fe26198 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:08:04 -0400 Subject: [PATCH 41/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index f5b583d9..f72a99a9 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -36,25 +36,24 @@ jobs: && sudo mv cuda-ubuntu2004-keyring.gpg /usr/share/keyrings/cuda-archive-keyring.gpg \ && sudo rm -f cuda-keyring_1.0-1_all.deb && sudo rm -f /etc/apt/sources.list.d/cuda.list + - name: Install Mamba + run: | + sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ + /bin/bash /tmp/mamba.sh -b -p /opt/conda && \ + sudo rm -rf /tmp/* && \ + sudo apt-get clean && \ + sudo rm -rf /var/lib/apt/lists/* + - name: Set system variables run: | echo '/opt/conda' >> $GITHUB_PATH -# source $GITHUB_PATH + source $GITHUB_PATH - name: Check if Custom Paths are Added run: | echo "$PATH" echo "$LD_LIBRARY_PATH" - - name: Install Mamba - run: | - sudo wget https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh -O /tmp/mamba.sh && \ - /bin/bash /tmp/mamba.sh -b -p /opt/conda && \ - sudo rm -rf /tmp/* && \ - sudo apt-get clean && \ - sudo rm -rf /var/lib/apt/lists/* - - - name: Install pyenv run: | pip install pipenv @@ -63,7 +62,7 @@ jobs: - name: Install dependencies run: | - sudo /opt/conda/mamba env create -f environment.yml \ + /opt/conda/mamba env create -f environment.yml \ echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH source $GITHUB_PATH From 2e2880cff0a5ef05faf77d87784c61da6a53264d Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:09:25 -0400 Subject: [PATCH 42/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index f72a99a9..d595f606 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -47,7 +47,7 @@ jobs: - name: Set system variables run: | echo '/opt/conda' >> $GITHUB_PATH - source $GITHUB_PATH +# source $GITHUB_PATH - name: Check if Custom Paths are Added run: | @@ -64,7 +64,7 @@ jobs: run: | /opt/conda/mamba env create -f environment.yml \ echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH - source $GITHUB_PATH +# source $GITHUB_PATH - name: Test with pytest run: | From 4f87ffd47b74a70035a2adc135bed9915548a2e2 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:13:24 -0400 Subject: [PATCH 43/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index d595f606..3d89babd 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -62,7 +62,7 @@ jobs: - name: Install dependencies run: | - /opt/conda/mamba env create -f environment.yml \ + /opt/conda/bin/mamba env create -f environment.yml \ echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH # source $GITHUB_PATH From 3650e6cfc1c2f7a7eeb4d917cb6ce61ecf67aaf0 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:16:09 -0400 Subject: [PATCH 44/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index 3d89babd..de7393b2 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -62,7 +62,7 @@ jobs: - name: Install dependencies run: | - /opt/conda/bin/mamba env create -f environment.yml \ + /opt/conda/bin/mamba env create -f environment.yml echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH # source $GITHUB_PATH From 64d883413eb61c0a3f73e2a9bd5954258c05b0c1 Mon Sep 17 00:00:00 2001 From: ms888ekb Date: Sun, 1 Oct 2023 15:32:29 -0400 Subject: [PATCH 45/45] changing the way the pytests are being run --- .github/workflows/github-actions-ci.yml | 26 +------------------------ 1 file changed, 1 insertion(+), 25 deletions(-) diff --git a/.github/workflows/github-actions-ci.yml b/.github/workflows/github-actions-ci.yml index de7393b2..05d00373 100644 --- a/.github/workflows/github-actions-ci.yml +++ b/.github/workflows/github-actions-ci.yml @@ -4,9 +4,6 @@ jobs: clean-and-deploy-env: runs-on: ubuntu-latest env: - CONDA_DIR: "/opt/conda" - USERNAME: "gdl_user" - USERID: "1000" LD_LIBRARY_PATH: "/opt/conda/lib" steps: - name: Free Disk Space (Ubuntu) @@ -47,7 +44,6 @@ jobs: - name: Set system variables run: | echo '/opt/conda' >> $GITHUB_PATH -# source $GITHUB_PATH - name: Check if Custom Paths are Added run: | @@ -64,27 +60,7 @@ jobs: run: | /opt/conda/bin/mamba env create -f environment.yml echo '/opt/conda/envs/geo_deep_env/bin' >> $GITHUB_PATH -# source $GITHUB_PATH - name: Test with pytest run: | - pipenv run pytest tests/ - - -# unit-tests: -# runs-on: ubuntu-latest -# needs: clean-and-deploy -# # runs within your Docker container -# container: -# image: geobaserepo/gdl-cuda11:v2.8.1 -# options: --user root -# # checkout your code from your repository -# # and runs pytest in your pipenv environment -# steps: -# - name: Install pipenv -# run: | -# pip install pipenv -# - uses: actions/checkout@v2 -# - name: Test with pytest -# run: | -# pipenv run pytest tests/ \ No newline at end of file + pipenv run pytest tests/ \ No newline at end of file