Repository: meteocat/pymica (language: python)

Issue:
From travis to github actions
Use github actions to test code and build conda package.
From travis to github actions
Use github actions to test code and build conda package.
From travis to github actions
Use github actions to test code and build conda package.
From travis to github actions
Use github actions to test code and build conda package.


Discussion / hints:

Fix patch:
diff --git a/.github/workflows/python-package-conda.yml b/.github/workflows/python-package-conda.yml
index 03f4888..3a3efe6 100644
--- a/.github/workflows/python-package-conda.yml
+++ b/.github/workflows/python-package-conda.yml
@@ -18,11 +18,20 @@ jobs:
       run: |
         # $CONDA is an environment variable pointing to the root of the miniconda directory
         echo $CONDA/bin >> $GITHUB_PATH
-    - name: Install dependencies
-      run: |
-        conda env update --file environment_dev.yml --name base
+    #- name: Install dependencies
+    #  run: |
+    #    # conda env update --file environment_dev.yml --name base
+    #    conda env create --file environment_dev.yml --name pymica-dev 
+    #    # $CONDA/bin/activate pymica-dev
+    - name: Setup conda environment
+      uses: conda-incubator/setup-miniconda@v2
+      with:
+        auto-activate-base: true
+        activate-environment: pymica-dev
+        environment-file: environment_dev.yml
     - name: Lint with flake8
       run: |
+        source /usr/share/miniconda/bin/activate pymica-dev
         conda install flake8
         # stop the build if there are Python syntax errors or undefined names
         flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
@@ -30,7 +39,8 @@ jobs:
         flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
     - name: Test with pytest
       run: |
-        python /home/runner/work/pymica/setup.py build_ext --inplace
+        source /usr/share/miniconda/bin/activate pymica-dev
+        python /home/runner/work/pymica/pymica/setup.py build_ext --inplace
         conda install pytest
         export PYTHONPATH=$PYTHONPATH:/home/runner/work/pymica/pymica/
         pytest
diff --git a/environment_dev.yml b/environment_dev.yml
index a40249e..f4596ec 100644
--- a/environment_dev.yml
+++ b/environment_dev.yml
@@ -1,154 +1,147 @@
-# This file may be used to create an environment using:
-# $ conda create --name <env> --file <this file>
-# platform: linux-64
-alabaster=0.7.12=py37_0
-asn1crypto=0.24.0=py37_0
-astroid=2.0.4=py37_0
-babel=2.6.0=py37_0
-backcall=0.1.0=py37_0
-blas=1.0=mkl
-bleach=3.0.2=py37_0
-bzip2=1.0.6=h14c3975_5
-ca-certificates=2019.5.15=0
-cairo=1.14.12=h8948797_3
-certifi=2019.3.9=py37_0
-cffi=1.11.5=py37he75722e_1
-chardet=3.0.4=py37_1
-cryptography=2.7=py37h1ba5d50_0
-curl=7.64.1=hbc83047_0
-cython=0.29=py37he6710b0_0
-dbus=1.13.2=h714fa37_1
-decorator=4.3.0=py37_0
-docutils=0.14=py37_0
-entrypoints=0.2.3=py37_2
-expat=2.2.6=he6710b0_0
-flake8=3.5.0=py37_1
-fontconfig=2.13.0=h9420a91_0
-freetype=2.9.1=h8a8886c_1
-freexl=1.0.5=h14c3975_0
-gdal=2.3.3=py37hbb2a789_0
-geos=3.7.1=he6710b0_0
-giflib=5.1.4=h14c3975_1
-glib=2.56.2=hd408876_0
-gmp=6.1.2=h6c8ec71_1
-gst-plugins-base=1.14.0=hbbd80ab_1
-gstreamer=1.14.0=hb453b48_1
-hdf4=4.2.13=h3ca952b_2
-hdf5=1.10.4=hb1b8bf9_0
-icu=58.2=h9c2bf20_1
-idna=2.7=py37_0
-imagesize=1.1.0=py37_0
-intel-openmp=2019.0=118
-ipykernel=5.1.0=py37h39e3cac_0
-ipython=7.2.0=py37h39e3cac_0
-ipython_genutils=0.2.0=py37_0
-ipywidgets=7.4.2=py37_0
-isort=4.3.4=py37_0
-jedi=0.13.2=py37_0
-jinja2=2.10.1=py37_0
-jpeg=9b=h024ee3a_2
-json-c=0.13.1=h1bed415_0
-jsonschema=2.6.0=py37_0
-jupyter=1.0.0=py37_7
-jupyter_client=5.2.4=py37_0
-jupyter_console=6.0.0=py37_0
-jupyter_core=4.4.0=py37_0
-kealib=1.4.7=hd0c454d_6
-krb5=1.16.1=h173b8e3_7
-lazy-object-proxy=1.3.1=py37h14c3975_2
-libboost=1.67.0=h46d08c1_4
-libcurl=7.64.1=h20c2e04_0
-libdap4=3.19.1=h6ec2957_0
-libedit=3.1.20170329=h6b74fdf_2
-libffi=3.2.1=hd88cf55_4
-libgcc-ng=8.2.0=hdf63c60_1
-libgdal=2.3.3=h2e7e64b_0
-libgfortran-ng=7.3.0=hdf63c60_0
-libkml=1.3.0=h590aaf7_4
-libnetcdf=4.6.1=h11d0813_2
-libpng=1.6.35=hbc83047_0
-libpq=11.2=h20c2e04_0
-libsodium=1.0.16=h1bed415_0
-libspatialite=4.3.0a=hb08deb6_19
-libssh2=1.8.2=h1ba5d50_0
-libstdcxx-ng=8.2.0=hdf63c60_1
-libtiff=4.0.9=he85c1e1_2
-libuuid=1.0.3=h1bed415_2
-libxcb=1.13=h1bed415_1
-libxml2=2.9.8=h26e45fe_1
-markupsafe=1.0=py37h14c3975_1
-mccabe=0.6.1=py37_1
-mistune=0.8.4=py37h7b6447c_0
-mkl=2018.0.3=1
-mkl_fft=1.0.6=py37h7dd41cf_0
-mkl_random=1.0.1=py37h4414c95_1
-nbconvert=5.3.1=py37_0
-nbformat=4.4.0=py37_0
-ncurses=6.1=hf484d3e_0
-notebook=5.7.8=py37_0
-numpy=1.15.4=py37h1d66e8a_0
-numpy-base=1.15.4=py37h81de0dd_0
-olefile=0.46=py37_0
-openjpeg=2.3.0=h05c96fa_1
-openssl=1.1.1c=h7b6447c_1
-packaging=18.0=py37_0
-pandoc=2.2.3.2=0
-pandocfilters=1.4.2=py37_1
-parso=0.3.1=py37_0
-pcre=8.42=h439df22_0
-pexpect=4.6.0=py37_0
-pickleshare=0.7.5=py37_0
-pillow=5.3.0=py37h34e0f95_0
-pip=10.0.1=py37_0
-pixman=0.34.0=hceecf20_3
-poppler=0.65.0=h581218d_1
-poppler-data=0.4.9=0
-proj4=5.2.0=he6710b0_1
-prometheus_client=0.5.0=py37_0
-prompt_toolkit=2.0.7=py37_0
-ptyprocess=0.6.0=py37_0
-pycodestyle=2.4.0=py37_0
-pycparser=2.19=py37_0
-pyflakes=1.6.0=py37_0
-pygments=2.2.0=py37_0
-pylint=2.1.1=py37_0
-pyopenssl=18.0.0=py37_0
-pyparsing=2.2.2=py37_0
-pyproj=1.9.6=py37h14380d9_0
-pyqt=5.9.2=py37h05f1152_2
-pysocks=1.6.8=py37_0
-python=3.7.2=h0371630_0
-python-dateutil=2.7.5=py37_0
-pytz=2018.5=py37_0
-pyzmq=17.1.2=py37h14c3975_0
-qt=5.9.7=h5867ecd_1
-qtconsole=4.4.3=py37_0
-readline=7.0=h7b6447c_5
-requests=2.22.0=py37_0
-rope=0.11.0=py37_0
-scikit-learn=0.20.0=py37h4989274_1
-scipy=1.1.0=py37hfa4b5c9_1
-send2trash=1.5.0=py37_0
-setuptools=40.4.3=py37_0
-sip=4.19.8=py37hf484d3e_0
-six=1.11.0=py37_1
-snowballstemmer=1.2.1=py37_0
-sphinx=1.8.1=py37_0
-sphinxcontrib=1.0=py37_1
-sphinxcontrib-websupport=1.1.0=py37_1
-sqlite=3.26.0=h7b6447c_0
-terminado=0.8.1=py37_1
-testpath=0.4.2=py37_0
-tk=8.6.8=hbc83047_0
-tornado=5.1.1=py37h7b6447c_0
-traitlets=4.3.2=py37_0
-urllib3=1.24.2=py37_0
-wcwidth=0.1.7=py37_0
-webencodings=0.5.1=py37_1
-wheel=0.32.1=py37_0
-widgetsnbextension=3.4.2=py37_0
-wrapt=1.10.11=py37h14c3975_2
-xerces-c=3.2.2=h780794e_0
-xz=5.2.4=h14c3975_4
-zeromq=4.2.5=hf484d3e_1
-zlib=1.2.11=ha838bed_2
+name: pymica-dev
+channels:
+  - conda-forge
+  - defaults
+dependencies:
+  - _libgcc_mutex=0.1=conda_forge
+  - _openmp_mutex=4.5=2_gnu
+  - blosc=1.21.5=h0f2a231_0
+  - boost-cpp=1.78.0=h2c5509c_4
+  - brotli-python=1.1.0=py311hb755f60_0
+  - bzip2=1.0.8=h7f98852_4
+  - c-ares=1.19.1=hd590300_0
+  - ca-certificates=2023.7.22=hbcca054_0
+  - cairo=1.16.0=h0c91306_1017
+  - certifi=2023.7.22=pyhd8ed1ab_0
+  - cfitsio=4.3.0=hbdc6101_0
+  - charset-normalizer=3.2.0=pyhd8ed1ab_0
+  - colorama=0.4.6=pyhd8ed1ab_0
+  - coverage=7.3.0=py311h459d7ec_0
+  - cython=3.0.2=py311hb755f60_0
+  - exceptiongroup=1.1.3=pyhd8ed1ab_0
+  - expat=2.5.0=hcb278e6_1
+  - font-ttf-dejavu-sans-mono=2.37=hab24e00_0
+  - font-ttf-inconsolata=3.000=h77eed37_0
+  - font-ttf-source-code-pro=2.038=h77eed37_0
+  - font-ttf-ubuntu=0.83=hab24e00_0
+  - fontconfig=2.14.2=h14ed4e7_0
+  - fonts-conda-ecosystem=1=0
+  - fonts-conda-forge=1=0
+  - freetype=2.12.1=hca18f0e_1
+  - freexl=1.0.6=h166bdaf_1
+  - gdal=3.7.1=py311h815a124_9
+  - geos=3.12.0=h59595ed_0
+  - geotiff=1.7.1=h22adcc9_11
+  - gettext=0.21.1=h27087fc_0
+  - giflib=5.2.1=h0b41bf4_3
+  - hdf4=4.2.15=h501b40f_6
+  - hdf5=1.14.2=nompi_h4f84152_100
+  - icu=73.2=h59595ed_0
+  - idna=3.4=pyhd8ed1ab_0
+  - iniconfig=2.0.0=pyhd8ed1ab_0
+  - joblib=1.3.2=pyhd8ed1ab_0
+  - json-c=0.17=h7ab15ed_0
+  - kealib=1.5.1=hcd42e92_5
+  - keyutils=1.6.1=h166bdaf_0
+  - krb5=1.21.2=h659d440_0
+  - lcms2=2.15=haa2dc70_1
+  - ld_impl_linux-64=2.40=h41732ed_0
+  - lerc=4.0.0=h27087fc_0
+  - libaec=1.0.6=hcb278e6_1
+  - libarchive=3.6.2=h039dbb9_1
+  - libblas=3.9.0=18_linux64_openblas
+  - libcblas=3.9.0=18_linux64_openblas
+  - libcurl=8.2.1=hca28451_0
+  - libdeflate=1.18=h0b41bf4_0
+  - libedit=3.1.20191231=he28a2e2_2
+  - libev=4.33=h516909a_1
+  - libexpat=2.5.0=hcb278e6_1
+  - libffi=3.4.2=h7f98852_5
+  - libgcc-ng=13.1.0=he5830b7_0
+  - libgdal=3.7.1=h880a63b_9
+  - libgfortran-ng=13.1.0=h69a702a_0
+  - libgfortran5=13.1.0=h15d22d2_0
+  - libglib=2.76.4=hebfc3b9_0
+  - libgomp=13.1.0=he5830b7_0
+  - libiconv=1.17=h166bdaf_0
+  - libjpeg-turbo=2.1.5.1=h0b41bf4_0
+  - libkml=1.3.0=h37653c0_1015
+  - liblapack=3.9.0=18_linux64_openblas
+  - libnetcdf=4.9.2=nompi_h80fb2b6_112
+  - libnghttp2=1.52.0=h61bc06f_0
+  - libnsl=2.0.0=h7f98852_0
+  - libopenblas=0.3.24=pthreads_h413a1c8_0
+  - libpng=1.6.39=h753d276_0
+  - libpq=15.4=hfc447b1_0
+  - librttopo=1.1.0=hb58d41b_14
+  - libspatialite=5.0.1=h15f6e67_28
+  - libsqlite=3.43.0=h2797004_0
+  - libssh2=1.11.0=h0841786_0
+  - libstdcxx-ng=13.1.0=hfd8a6a1_0
+  - libtiff=4.5.1=h8b53f26_1
+  - libuuid=2.38.1=h0b41bf4_0
+  - libwebp-base=1.3.1=hd590300_0
+  - libxcb=1.15=h0b41bf4_0
+  - libxml2=2.11.5=h232c23b_1
+  - libzip=1.10.1=h2629f0a_2
+  - libzlib=1.2.13=hd590300_5
+  - lz4-c=1.9.4=hcb278e6_0
+  - lzo=2.10=h516909a_1000
+  - ncurses=6.4=hcb278e6_0
+  - nspr=4.35=h27087fc_0
+  - nss=3.92=h1d7d5a4_0
+  - numpy=1.25.2=py311h64a7726_0
+  - openjpeg=2.5.0=hfec8fc6_2
+  - openssl=3.1.2=hd590300_0
+  - packaging=23.1=pyhd8ed1ab_0
+  - pcre2=10.40=hc3806b6_0
+  - pip=23.2.1=pyhd8ed1ab_0
+  - pixman=0.40.0=h36c2ea0_0
+  - platformdirs=3.10.0=pyhd8ed1ab_0
+  - pluggy=1.3.0=pyhd8ed1ab_0
+  - pooch=1.7.0=pyha770c72_3
+  - poppler=23.08.0=hd18248d_0
+  - poppler-data=0.4.12=hd8ed1ab_0
+  - postgresql=15.4=h8972f4a_0
+  - proj=9.2.1=ha643af7_0
+  - pthread-stubs=0.4=h36c2ea0_1001
+  - pyproj=3.6.0=py311ha169711_1
+  - pysocks=1.7.1=pyha2e5f31_6
+  - pytest=7.4.1=pyhd8ed1ab_0
+  - pytest-cov=4.1.0=pyhd8ed1ab_0
+  - python=3.11.5=hab00c5b_0_cpython
+  - python_abi=3.11=3_cp311
+  - readline=8.2=h8228510_1
+  - requests=2.31.0=pyhd8ed1ab_0
+  - scikit-learn=1.3.0=py311hc009520_0
+  - scipy=1.11.2=py311h64a7726_0
+  - setuptools=68.1.2=pyhd8ed1ab_0
+  - snappy=1.1.10=h9fff704_0
+  - sqlite=3.43.0=h2c6b66d_0
+  - threadpoolctl=3.2.0=pyha21a80b_0
+  - tiledb=2.16.3=hf0b6e87_1
+  - tk=8.6.12=h27826a3_0
+  - toml=0.10.2=pyhd8ed1ab_0
+  - tomli=2.0.1=pyhd8ed1ab_0
+  - typing-extensions=4.7.1=hd8ed1ab_0
+  - typing_extensions=4.7.1=pyha770c72_0
+  - tzcode=2023c=h0b41bf4_0
+  - tzdata=2023c=h71feb2d_0
+  - urllib3=2.0.4=pyhd8ed1ab_0
+  - wheel=0.41.2=pyhd8ed1ab_0
+  - xerces-c=3.2.4=hac6953d_3
+  - xorg-kbproto=1.0.7=h7f98852_1002
+  - xorg-libice=1.1.1=hd590300_0
+  - xorg-libsm=1.2.4=h7391055_0
+  - xorg-libx11=1.8.6=h8ee46fc_0
+  - xorg-libxau=1.0.11=hd590300_0
+  - xorg-libxdmcp=1.1.3=h7f98852_0
+  - xorg-libxext=1.3.4=h0b41bf4_2
+  - xorg-libxrender=0.9.11=hd590300_0
+  - xorg-renderproto=0.11.1=h7f98852_1002
+  - xorg-xextproto=7.3.0=h0b41bf4_1003
+  - xorg-xproto=7.0.31=h7f98852_1007
+  - xz=5.2.6=h166bdaf_0
+  - zlib=1.2.13=hd590300_5
+  - zstd=1.5.5=hfc55251_0
+prefix: /home/ecm/anaconda3/envs/pymica-dev
diff --git a/setup.py b/setup.py
index 7bba8a7..9c6fc78 100644
--- a/setup.py
+++ b/setup.py
@@ -2,14 +2,12 @@
 Run python setup.py --help for options
 '''
 import datetime
-import subprocess
 
 import numpy
 import setuptools
 
-release = subprocess.check_output(
-    ['git', 'describe', '--abbrev=0', '--tags']).decode('utf-8').strip()
-version = ".".join(release.split('.')[0:2])
+release = "0.1.0"
+version = "0.1.0"
 name = "pymica"
 
 now = datetime.datetime.now()


Test patch:
diff --git a/pymica_tests/apply_regression_test.py b/pymica_tests/apply_regression_test.py
index 858e728..289eff3 100644
--- a/pymica_tests/apply_regression_test.py
+++ b/pymica_tests/apply_regression_test.py
@@ -93,11 +93,11 @@ def test_apply_regression_errors(self):
             str(cm.exception))
 
     def test_apply_clustered_regression(self):
-        f_p = open("./pymica_tests/data/sample_data.json")
+        f_p = open("pymica_tests/data/sample_data.json")
         data = json.load(f_p)
         f_p.close()
         inst = ClusteredRegression(data,
-                                   ["./pymica_tests/data/clusters.json"])
+                                   ["pymica_tests/data/clusters.json"])
 
         size = [1000, 1000]
         alt_data = np.ones(size)
diff --git a/pymica_tests/clustered_regression_test.py b/pymica_tests/clustered_regression_test.py
index c340e09..b450ef5 100644
--- a/pymica_tests/clustered_regression_test.py
+++ b/pymica_tests/clustered_regression_test.py
@@ -8,11 +8,11 @@
 
 class TestClusteredRegression(unittest.TestCase):
     def test_regression_ideal_data(self):
-        f_p = open("./pymica_tests/data/sample_data.json")
+        f_p = open("pymica_tests/data/sample_data.json")
         data = json.load(f_p)
         f_p.close()
         inst = ClusteredRegression(data,
-                                   ["./pymica_tests/data/clusters.json"])
+                                   ["pymica_tests/data/clusters.json"])
         self.assertEqual(len(inst.final_data), 3)
         self.assertAlmostEqual(inst.mse, 2.1828, 3)
 
@@ -29,22 +29,22 @@ def test_regression_ideal_data(self):
             str(cm.exception))
 
     def test_get_residuals(self):
-        f_p = open("./pymica_tests/data/sample_data.json")
+        f_p = open("pymica_tests/data/sample_data.json")
         data = json.load(f_p)
         f_p.close()
         inst = ClusteredRegression(data,
-                                   ["./pymica_tests/data/clusters.json"])
+                                   ["pymica_tests/data/clusters.json"])
         result = inst.get_residuals()
         self.assertEqual(len(data), len(result))
         for point in data:
             self.assertTrue(point['id'] in result)
 
     def test_predict_points(self):
-        f_p = open("./pymica_tests/data/sample_data.json")
+        f_p = open("pymica_tests/data/sample_data.json")
         data = json.load(f_p)
         f_p.close()
         inst = ClusteredRegression(data,
-                                   ["./pymica_tests/data/clusters.json"])
+                                   ["pymica_tests/data/clusters.json"])
         sample_data = [{"id": "C6", "temp": 6.4, "altitude": 264,
                         "lon": 0.95172, "lat": 41.6566,
                         "dist": 0.8583929293407604},
diff --git a/pymica_tests/create_cluster_files_test.py b/pymica_tests/create_cluster_files_test.py
index 4717cc6..07fd3b8 100644
--- a/pymica_tests/create_cluster_files_test.py
+++ b/pymica_tests/create_cluster_files_test.py
@@ -13,7 +13,7 @@
 
 class TestCreateClustersFiles(unittest.TestCase):
     def test_create_reprojected_geoms(self):
-        d_s = create_reprojected_geoms("./pymica_tests/data/clusters.json", 25831)
+        d_s = create_reprojected_geoms("pymica_tests/data/clusters.json", 25831)
 
         self.assertIsInstance(d_s, ogr.DataSource)
         layer = d_s.GetLayer()
@@ -28,7 +28,7 @@ def test_create_reprojected_geoms(self):
             str(c_m.exception))
 
         with self.assertRaises(ValueError) as c_m:
-            create_reprojected_geoms("./pymica_tests/data/clusters.json", -999)
+            create_reprojected_geoms("pymica_tests/data/clusters.json", -999)
         self.assertEqual(
             "Wrong EPSG code: -999",
             str(c_m.exception))
@@ -39,7 +39,7 @@ def test_rasterize_clusters(self):
         if exists(out_file):
             remove(out_file)
 
-        layer = create_reprojected_geoms("./pymica_tests/data/clusters.json", 25831)
+        layer = create_reprojected_geoms("pymica_tests/data/clusters.json", 25831)
         rasterize_clusters(layer,
                            {'size': [1000, 1000],
                             'geotransform': geotransform,
diff --git a/pymica_tests/distance_to_sea_test.py b/pymica_tests/distance_to_sea_test.py
index 7c86731..1842627 100644
--- a/pymica_tests/distance_to_sea_test.py
+++ b/pymica_tests/distance_to_sea_test.py
@@ -13,7 +13,7 @@ def test_dist2func(self):
         self.assertAlmostEqual(dist2func(200000), dist2func(300000), 2)
 
     def test_get_distances(self):
-        result = get_distances([[1, 41]], "./pymica_tests/data/coast_line.json")
+        result = get_distances([[1, 41]], "pymica_tests/data/coast_line.json")
 
         self.assertEqual(len(result), 1)
         self.assertTrue(abs(result[0] - 3910) < 1)
@@ -27,6 +27,6 @@ def test_get_distances(self):
     def test_get_dist_array(self):
         result = get_dist_array(25831, (420244, 30, 0, 4581058, 0, -30),
                                 (1000, 10),
-                                "./pymica_tests/data/coast_line.json")
+                                "pymica_tests/data/coast_line.json")
         self.assertEqual(result.shape, (10, 1000))
         self.assertTrue((result <= 1).all() and (result >= 0).all())
diff --git a/pymica_tests/pymica2_test.py b/pymica_tests/pymica2_test.py
index 3677932..595d412 100644
--- a/pymica_tests/pymica2_test.py
+++ b/pymica_tests/pymica2_test.py
@@ -3,7 +3,7 @@
 from genericpath import exists
 import io
 import json
-from os import remove
+from os import remove, makedirs, rmdir
 import unittest
 import unittest.mock
 
@@ -27,10 +27,12 @@ def setUpClass(cls):
         proj = osr.SpatialReference()
         proj.ImportFromEPSG(25831)
 
+        makedirs('pymica_tests/data/tifs/')
+
         driver = gdal.GetDriverByName('GTiff')
 
         # Create fake altitude field
-        d_s = driver.Create('./pymica_tests/data/tifs/altitude.tif',
+        d_s = driver.Create('pymica_tests/data/tifs/altitude.tif',
                             size[1], size[0], 1, gdal.GDT_Float32)
         d_s.GetRasterBand(1).WriteArray(alt_data)
         d_s.SetGeoTransform((260000, 270, 0, 4750000, 0, -270))
@@ -38,7 +40,7 @@ def setUpClass(cls):
         d_s = None
 
         # Create fake distance to coast field
-        d_s = driver.Create('./pymica_tests/data/tifs/d_coast.tif',
+        d_s = driver.Create('pymica_tests/data/tifs/d_coast.tif',
                             size[1], size[0], 1, gdal.GDT_Float32)
         d_s.GetRasterBand(1).WriteArray(dist_data)
         d_s.SetGeoTransform((260000, 270, 0, 4750000, 0, -270))
@@ -46,7 +48,7 @@ def setUpClass(cls):
         d_s = None
 
         # Create wrong fake distance to coast field
-        d_s = driver.Create('./pymica_tests/data/tifs/d_coast_2.tif',
+        d_s = driver.Create('pymica_tests/data/tifs/d_coast_2.tif',
                             3, 3, 1, gdal.GDT_Float32)
         d_s.GetRasterBand(1).WriteArray(dist_data[:3, :3])
         d_s.SetGeoTransform((260000, 270, 0, 4750000, 0, -270))
@@ -60,7 +62,7 @@ def setUpClass(cls):
                 {'id': 'C', 'lon': 2.7567764, 'lat': 42.4520729,
                  'altitude': 1000, 'value': 10.0}]
 
-        with open('./pymica_tests/data/init_data.json', 'w') as f:
+        with open('pymica_tests/data/init_data.json', 'w') as f:
             json.dump(data, f)
             f.close()
 
@@ -72,18 +74,18 @@ def setUpClass(cls):
                                                     530000, 4750000],
                            'EPSG': 25831,
                            'variables_files': {'altitude':
-                                               './pymica_tests/data/tifs/altitude.tif'}},
+                                               'pymica_tests/data/tifs/altitude.tif'}},
                   'mlr': {'clusters': None,
                           'resolution': 270,
                           'interpolation_bounds': [260000, 4480000,
                                                    530000, 4750000],
                           'EPSG': 25831,
                           'variables_files': {'altitude':
-                                              './pymica_tests/data/tifs/altitude.tif',
+                                              'pymica_tests/data/tifs/altitude.tif',
                                               'd_coast':
-                                              './pymica_tests/data/tifs/d_coast.tif'}}}
+                                              'pymica_tests/data/tifs/d_coast.tif'}}}
 
-        with open('./pymica_tests/data/config_interpolate.json', 'w') as f:
+        with open('pymica_tests/data/config_interpolate.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
@@ -92,18 +94,18 @@ def test_init_wrong_variables_files(cls):
                           'interpolation_bounds': [260000, 4480000,
                                                    530000, 4750000],
                           'clusters': 'None',
-                          'variables_files': {'altitude': './pymica_tests/data/tifs/'
+                          'variables_files': {'altitude': 'pymica_tests/data/tifs/'
                                                           'altitude.tif',
-                                              'd_coast': './pymica_tests/data/tifs/'
+                                              'd_coast': 'pymica_tests/data/tifs/'
                                                          'd_coast_2.tif'},
                           'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with cls.assertRaises(ValueError) as cm:
-            PyMica('mlr', './pymica_tests/data/config_test.json')
+            PyMica('mlr', 'pymica_tests/data/config_test.json')
         cls.assertEqual('Variables properties are not the same. '
                         'Variables fields must have the same '
                         'GeoTransform, Projection, XSize and YSize.',
@@ -116,14 +118,14 @@ def test_init_config_not_found(self):
 
     def test_init_config_json_error(self):
         with self.assertRaises(json.decoder.JSONDecodeError) as cm:
-            PyMica('id3d', './pymica_tests/data/config_error.json')
+            PyMica('id3d', 'pymica_tests/data/config_error.json')
         self.assertEqual('Expecting property name enclosed in double quotes: '
                          'line 2 column 5 (char 6)',
                          str(cm.exception))
 
     def test_init_wrong_methodology(self):
         with self.assertRaises(ValueError) as cm:
-            PyMica('id3', './pymica_tests/data/config_interpolate.json')
+            PyMica('id3', 'pymica_tests/data/config_interpolate.json')
         self.assertEqual('Methodology must be \"id2d\", \"id3d\", '
                          '\"mlr+id2d\", \"mlr+id3d\" or \"mlr\"',
                          str(cm.exception))
@@ -135,14 +137,14 @@ def test_init_methodology_not_in_config(self):
                                                     530000, 4750000],
                            'EPSG': 25831,
                            'variables_files': {'altitude':
-                                               './pymica_tests/data/tifs/altitude.tif'}}}
+                                               'pymica_tests/data/tifs/altitude.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('id2d not defined in the configuration file.',
                          cm.exception.args[0])
 
@@ -153,16 +155,16 @@ def test_init_default_values_config(self):
                                                     530000, 4750000],
                            'EPSG': 25831,
                            'variables_files': {'altitude':
-                                               './pymica_tests/data/tifs/altitude.tif'}}}
+                                               'pymica_tests/data/tifs/altitude.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with unittest.mock.patch('sys.stdout',
                                  new_callable=io.StringIO) as mock_stdout:
             inst = PyMica('id3d',
-                          './pymica_tests/data/config_test.json')
+                          'pymica_tests/data/config_test.json')
         self.assertEqual(mock_stdout.getvalue().strip(),
                          'id_power not in the configuration dictionary.'
                          ' id_power set to default value of 2.5.\n'
@@ -181,12 +183,12 @@ def test_init_missing_interpolation_bounds(self):
                            'resolution': 1000,
                            'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('interpolation_bounds must be defined in the '
                          'configuration dictionary.', cm.exception.args[0])
 
@@ -198,12 +200,12 @@ def test_init_wrong_type_interpolation_bounds(self):
                            'resolution': 1000,
                            'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(TypeError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('interpolation_bounds must be a List as '
                          '[x_min, y_min, x_max, y_max]', cm.exception.args[0])
 
@@ -215,12 +217,12 @@ def test_init_wrong_length_interpolation_bounds(self):
                            'resolution': 1000,
                            'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(ValueError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('interpolation_bounds must be a List as '
                          '[x_min, y_min, x_max, y_max]', cm.exception.args[0])
 
@@ -231,12 +233,12 @@ def test_init_missing_resolution(self):
                            'interpolation_bounds': [0, 0, 1000, 1000],
                            'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('resolution must be defined in the configuration '
                          'dictionary.', cm.exception.args[0])
 
@@ -248,12 +250,12 @@ def test_init_wrong_type_resolution(self):
                            'resolution': '1000',
                            'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(TypeError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('resolution must have a valid value in meters.',
                          cm.exception.args[0])
 
@@ -264,12 +266,12 @@ def test_init_missing_epsg(self):
                            'interpolation_bounds': [0, 0, 1000, 1000],
                            'resolution': 1000}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('EPSG must be defined in the configuration '
                          'dictionary.', cm.exception.args[0])
 
@@ -281,12 +283,12 @@ def test_init_wrong_type_epsg(self):
                            'resolution': 1000,
                            'EPSG': '25831'}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(TypeError) as cm:
-            PyMica('id2d', './pymica_tests/data/config_test.json')
+            PyMica('id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('EPSG must have a valid int value.',
                          cm.exception.args[0])
 
@@ -298,12 +300,12 @@ def test_init_missing_variables_files(self):
                                'resolution': 1000,
                                'EPSG': 25831}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            PyMica('mlr+id2d', './pymica_tests/data/config_test.json')
+            PyMica('mlr+id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('variables_files must be included in the ' +
                          'configuration file if mlr+id2d is selected.',
                          cm.exception.args[0])
@@ -317,12 +319,12 @@ def test_init_empty_variables_files(self):
                                'EPSG': 25831,
                                'variables_files': {}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(ValueError) as cm:
-            PyMica('mlr+id2d', './pymica_tests/data/config_test.json')
+            PyMica('mlr+id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('variables_files dictionary must have at ' +
                          'least one key including a variable file ' +
                          'path containing a 2D predictor field.',
@@ -338,12 +340,12 @@ def test_init_not_found_variables_files(self):
                                'variables_files': {'altitude':
                                                    'notfound.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
         with self.assertRaises(FileNotFoundError) as cm:
-            PyMica('mlr+id2d', './pymica_tests/data/config_test.json')
+            PyMica('mlr+id2d', 'pymica_tests/data/config_test.json')
         self.assertEqual('No such file or directory: notfound.tif',
                          str(cm.exception))
 
@@ -356,14 +358,14 @@ def test_init_two_variables_files(self):
                                'resolution': 270,
                                'EPSG': 25831,
                                'variables_files': {
-                                   'altitude': './pymica_tests/data/tifs/altitude.tif',
-                                   'd_coast': './pymica_tests/data/tifs/d_coast.tif'}}}
+                                   'altitude': 'pymica_tests/data/tifs/altitude.tif',
+                                   'd_coast': 'pymica_tests/data/tifs/d_coast.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        mlr_id2d = PyMica('mlr+id2d', './pymica_tests/data/config_test.json')
+        mlr_id2d = PyMica('mlr+id2d', 'pymica_tests/data/config_test.json')
 
         self.assertEqual(mlr_id2d.variables.shape, (2, 1000, 1000))
 
@@ -376,15 +378,15 @@ def test_init_interpolate_id2d(self):
                            'resolution': 270,
                            'EPSG': 25831,
                            'variables_files': {
-                               'altitude': './pymica_tests/data/tifs/altitude.tif',
-                               'd_coast': './pymica_tests/data/tifs/d_coast.tif'}}}
+                               'altitude': 'pymica_tests/data/tifs/altitude.tif',
+                               'd_coast': 'pymica_tests/data/tifs/d_coast.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        id2d = PyMica('id2d', './pymica_tests/data/config_test.json')
-        field = id2d.interpolate('./pymica_tests/data/init_data.json')
+        id2d = PyMica('id2d', 'pymica_tests/data/config_test.json')
+        field = id2d.interpolate('pymica_tests/data/init_data.json')
 
         self.assertEqual(field.shape, (1000, 1000))
         self.assertAlmostEqual(field[0, 0], 23.992, 2)
@@ -400,15 +402,15 @@ def test_init_interpolate_id3d(self):
                            'resolution': 270,
                            'EPSG': 25831,
                            'variables_files': {
-                               'altitude': './pymica_tests/data/tifs/altitude.tif',
-                               'd_coast': './pymica_tests/data/tifs/d_coast.tif'}}}
+                               'altitude': 'pymica_tests/data/tifs/altitude.tif',
+                               'd_coast': 'pymica_tests/data/tifs/d_coast.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        id3d = PyMica('id3d', './pymica_tests/data/config_test.json')
-        field = id3d.interpolate('./pymica_tests/data/init_data.json')
+        id3d = PyMica('id3d', 'pymica_tests/data/config_test.json')
+        field = id3d.interpolate('pymica_tests/data/init_data.json')
 
         self.assertEqual(field.shape, (1000, 1000))
         self.assertAlmostEqual(field[0, 0], 24.086, 2)
@@ -424,14 +426,14 @@ def test_init_interpolate_mlr(self):
                           'resolution': 270,
                           'EPSG': 25831,
                           'variables_files': {
-                              'altitude': './pymica_tests/data/tifs/altitude.tif'}}}
+                              'altitude': 'pymica_tests/data/tifs/altitude.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        mlr = PyMica('mlr', './pymica_tests/data/config_test.json')
-        field = mlr.interpolate('./pymica_tests/data/init_data.json')
+        mlr = PyMica('mlr', 'pymica_tests/data/config_test.json')
+        field = mlr.interpolate('pymica_tests/data/init_data.json')
 
         self.assertEqual(field.shape, (1000, 1000))
         self.assertAlmostEqual(field[0, 0], 37.193, 2)
@@ -447,14 +449,14 @@ def test_init_interpolate_mlr_id2d(self):
                                'resolution': 270,
                                'EPSG': 25831,
                                'variables_files': {
-                                   'altitude': './pymica_tests/data/tifs/altitude.tif'}}}
+                                   'altitude': 'pymica_tests/data/tifs/altitude.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        mlr_id2d = PyMica('mlr+id2d', './pymica_tests/data/config_test.json')
-        field = mlr_id2d.interpolate('./pymica_tests/data/init_data.json')
+        mlr_id2d = PyMica('mlr+id2d', 'pymica_tests/data/config_test.json')
+        field = mlr_id2d.interpolate('pymica_tests/data/init_data.json')
 
         self.assertEqual(field.shape, (1000, 1000))
         self.assertAlmostEqual(field[925, 74], 50.000, 2)
@@ -470,14 +472,14 @@ def test_init_interpolate_mlr_id3d(self):
                                'resolution': 270,
                                'EPSG': 25831,
                                'variables_files': {
-                                   'altitude': './pymica_tests/data/tifs/altitude.tif'}}}
+                                   'altitude': 'pymica_tests/data/tifs/altitude.tif'}}}
 
-        with open('./pymica_tests/data/config_test.json', 'w') as f:
+        with open('pymica_tests/data/config_test.json', 'w') as f:
             json.dump(config, f)
             f.close()
 
-        mlr_id2d = PyMica('mlr+id3d', './pymica_tests/data/config_test.json')
-        field = mlr_id2d.interpolate('./pymica_tests/data/init_data.json')
+        mlr_id2d = PyMica('mlr+id3d', 'pymica_tests/data/config_test.json')
+        field = mlr_id2d.interpolate('pymica_tests/data/init_data.json')
 
         self.assertEqual(field.shape, (1000, 1000))
         self.assertAlmostEqual(field[925, 74], 50.000, 2)
@@ -487,15 +489,15 @@ def test_init_interpolate_mlr_id3d(self):
     def test_interpolate_input_data_file_not_found(self):
 
         with self.assertRaises(FileNotFoundError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
             inst.interpolate(data_file='aaaa')
         self.assertEqual('No such file or directory: aaaa', str(cm.exception))
 
     def test_interpolate_input_bad_data_file(self):
 
         with self.assertRaises(json.decoder.JSONDecodeError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_err.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_err.json')
         self.assertEqual("Expecting ',' delimiter: line 1 column 3474 "
                          "(char 3473)", str(cm.exception))
 
@@ -508,13 +510,13 @@ def test_interpolate_input_bad_lat(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'dist': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('lat must be included in the data file',
                          cm.exception.args[0])
 
@@ -526,13 +528,13 @@ def test_interpolate_input_bad_lon(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'dist': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('lon must be included in the data file',
                          cm.exception.args[0])
 
@@ -543,13 +545,13 @@ def test_interpolate_input_altitude_missing(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'dist': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('altitude must be included in the data file',
                          cm.exception.args[0])
 
@@ -561,13 +563,13 @@ def test_interpolate_input_bad_id(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'dist': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('id must be included in the data file',
                          cm.exception.args[0])
 
@@ -579,13 +581,13 @@ def test_interpolate_input_value_missing(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'dist': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('id3d', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('id3d', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('value must be included in the data file',
                          cm.exception.args[0])
 
@@ -596,30 +598,32 @@ def test_interpolate_input_data_variable_missing(self):
                       'lon': 1.16234, 'lat': 41.66695,
                       'd_coast': 0.8387222708681318}]
 
-        with open('./pymica_tests/data/sample_data_test_keys.json', 'w') as f:
+        with open('pymica_tests/data/sample_data_test_keys.json', 'w') as f:
             json.dump(data_dict, f)
             f.close()
 
         with self.assertRaises(KeyError) as cm:
-            inst = PyMica('mlr', './pymica_tests/data/config_interpolate.json')
-            inst.interpolate(data_file='./pymica_tests/data/sample_data_test_keys.json')
+            inst = PyMica('mlr', 'pymica_tests/data/config_interpolate.json')
+            inst.interpolate(data_file='pymica_tests/data/sample_data_test_keys.json')
         self.assertEqual('Some of the variables provided in the '
                          'variables_files dictionary missing in C6.',
                          cm.exception.args[0])
 
     @classmethod
     def tearDownClass(self):
-        if exists('./pymica_tests/data/config_test.json'):
-            remove('./pymica_tests/data/config_test.json')
-        if exists('./pymica_tests/data/config_interpolate.json'):
-            remove('./pymica_tests/data/config_interpolate.json')
-        if exists('./pymica_tests/data/tifs/altitude.tif'):
-            remove('./pymica_tests/data/tifs/altitude.tif')
-        if exists('./pymica_tests/data/tifs/d_coast.tif'):
-            remove('./pymica_tests/data/tifs/d_coast.tif')
-        if exists('./pymica_tests/data/tifs/d_coast_2.tif'):
-            remove('./pymica_tests/data/tifs/d_coast_2.tif')
-        if exists('./pymica_tests/data/init_data.json'):
-            remove('./pymica_tests/data/init_data.json')
-        if exists('./pymica_tests/data/sample_data_test_keys.json'):
-            remove('./pymica_tests/data/sample_data_test_keys.json')
+        if exists('pymica_tests/data/config_test.json'):
+            remove('pymica_tests/data/config_test.json')
+        if exists('pymica_tests/data/config_interpolate.json'):
+            remove('pymica_tests/data/config_interpolate.json')
+        if exists('pymica_tests/data/tifs/altitude.tif'):
+            remove('pymica_tests/data/tifs/altitude.tif')
+        if exists('pymica_tests/data/tifs/d_coast.tif'):
+            remove('pymica_tests/data/tifs/d_coast.tif')
+        if exists('pymica_tests/data/tifs/d_coast_2.tif'):
+            remove('pymica_tests/data/tifs/d_coast_2.tif')
+        if exists('pymica_tests/data/init_data.json'):
+            remove('pymica_tests/data/init_data.json')
+        if exists('pymica_tests/data/sample_data_test_keys.json'):
+            remove('pymica_tests/data/sample_data_test_keys.json')
+        if exists('pymica_tests/data/tifs'):
+            rmdir('pymica_tests/data/tifs')
diff --git a/pymica_tests/pymica_test.py b/pymica_tests/pymica_test.py
deleted file mode 100644
index 493e908..0000000
--- a/pymica_tests/pymica_test.py
+++ /dev/null
@@ -1,126 +0,0 @@
-'''Tests for pymica.pymica.py
-'''
-import unittest
-from tempfile import gettempdir
-
-import numpy as np
-from osgeo import gdal, osr
-from pymica.pymica import PyMica
-
-
-class TestPyMica(unittest.TestCase):
-    @classmethod
-    def setUpClass(cls):
-        cls.variables_file = gettempdir() + '/variables.tiff'
-        cls.mask_file = gettempdir() + '/mask.tiff'
-        cls.mask5_file = gettempdir() + '/mask5.tiff'
-        cls.clusters = {'clusters_files': ["./pymica_tests/data/clusters.json"],
-                        'mask_files': [cls.mask_file]}
-        size = [1000, 1000]
-        alt_data = np.ones(size)
-        alt_data[2][2] = 12
-
-        dist_data = np.ones(size)
-
-        driver = gdal.GetDriverByName('GTiff')
-        d_s = driver.Create(cls.variables_file, size[1], size[0], 2,
-                            gdal.GDT_Float32)
-
-        d_s.GetRasterBand(1).WriteArray(alt_data)
-        d_s.GetRasterBand(2).WriteArray(dist_data)
-
-        d_s.SetGeoTransform((260000, 270, 0, 4750000, 0, -270))
-
-        proj = osr.SpatialReference()
-        proj.ImportFromEPSG(25831)
-
-        d_s.SetProjection(proj.ExportToWkt())
-
-        d_s = None
-
-        mask = np.zeros([3, 1000, 1000])
-        for i in range(3):
-            for j in range(500):
-                mask[i][i*250 + j][:] = 1 - j/550
-        d_s = driver.Create(cls.mask_file, size[1], size[0], 3,
-                            gdal.GDT_Float32)
-
-        for i in range(mask.shape[0]):
-            d_s.GetRasterBand(i + 1).WriteArray(mask[i])
-        d_s = None
-
-        mask5 = np.zeros([5, 1000, 1000])
-        for i in range(5):
-            for j in range(200):
-                mask5[i][i*200 + j][:] = 1 - j/550
-        d_s = driver.Create(cls.mask5_file, size[1], size[0], 5,
-                            gdal.GDT_Float32)
-
-        for i in range(mask5.shape[0]):
-            d_s.GetRasterBand(i + 1).WriteArray(mask5[i])
-        d_s = None
-
-    def test_init(self):
-        inst = PyMica("./pymica_tests/data/sample_data.json", self.variables_file,
-                      self.clusters)
-        self.assertEqual(inst.result.shape, (1000, 1000))
-
-        inst.save_file(gettempdir() + "/out.tiff")
-
-        # Test passing multiple variable files instead
-        # of one with all the layers
-        PyMica("./pymica_tests/data/sample_data.json", [self.variables_file],
-               self.clusters)
-
-        # No clusters
-        PyMica("./pymica_tests/data/sample_data.json", [self.variables_file])
-
-        # Multiple clusters
-        clusters2 = {'clusters_files': ["./pymica_tests/data/clusters.json",
-                                        "./pymica_tests/data/clusters5.json"],
-                     'mask_files': [self.mask_file, self.mask5_file]}
-        PyMica("./pymica_tests/data/sample_data.json", [self.variables_file],
-               clusters2)
-
-    def test_init_different_vars(self):
-        with open("./pymica_tests/data/sample_data.json") as d_s:
-            data = d_s.read()
-        with open(gettempdir() + "/sample_data.json", "w") as d_s:
-            d_s.write(data.replace('id', 'other_id')
-                          .replace('temp', 'other_var')
-                          .replace('dist', 'other_x_var'))
-
-        data_format = {'loc_vars': ('lon', 'lat'),
-                       'id_key': 'other_id',
-                       'y_var': 'other_var',
-                       'x_vars': ('altitude', 'other_x_var')}
-        inst = PyMica(gettempdir() + "/sample_data.json", self.variables_file,
-                      self.clusters, data_format)
-        self.assertEqual(inst.result.shape, (1000, 1000))
-
-    @unittest.skip
-    def test_errors(self):
-
-        with self.assertRaises(FileNotFoundError) as cm:
-            PyMica("BadFile", self.variables_file,
-                   self.clusters)
-        self.assertEqual(
-            "[Errno 2] No such file or directory: 'BadFile'",
-            str(cm.exception))
-
-        with self.assertRaises(FileNotFoundError) as cm:
-            PyMica("./pymica_tests/data/sample_data.json", ["BadFile"])
-        self.assertEqual(
-            "[Errno 2] No such file or directory: 'BadFile'",
-            str(cm.exception))
-
-        with self.assertRaises(ValueError) as cm:
-            PyMica("./pymica_tests/data/sample_data.json", self.variables_file,
-                   residuals_int='BadMethdology')
-        self.assertEqual(
-            "[Errno 2]residuals_int must be \"id2d\"," +
-            " \"id3d\" or \"idw\"",
-            str(cm.exception)
-            )
-        # TODO : mask doesn't exist or clusters bad formatted
-        # TODO : Bad variable names passed