Skip to content

Commit 4311a97

Browse files
Merge pull request #311 from cgre-aachen/dev_gemgis1
Dev gemgis1
2 parents bb5e9ac + dfc1909 commit 4311a97

File tree

9 files changed

+167
-142
lines changed

9 files changed

+167
-142
lines changed

.github/workflows/pypi_release.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@ jobs:
2626
- name: Install dependencies
2727
run: |
2828
python -m pip install --upgrade pip
29-
pip install setuptools wheel twine
30-
pip install -r requirements.txt
29+
#pip install setuptools wheel twine
30+
#pip install -r requirements.txt
31+
pip install gemgis[build]
3132
- name: Build and publish
3233
env:
3334
TWINE_USERNAME: ${{ secrets.PYPI_USERS }}

docs/conf.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@
2121
# -- GemGIS configuration ---------------------------------------------------
2222
import os
2323
import sys
24-
sys.path.insert(0, os.path.abspath(".."))
25-
sys.path.insert(0, os.path.abspath('../..'))
26-
sys.path.insert(0, os.path.abspath("gemgis/"))
27-
sys.path.insert(0, os.path.abspath("../gemgis/"))
28-
sys.path.insert(0, os.path.abspath("../../gemgis/"))
24+
#sys.path.insert(0, os.path.abspath(".."))
25+
#sys.path.insert(0, os.path.abspath('../..'))
26+
#sys.path.insert(0, os.path.abspath("gemgis/"))
27+
#sys.path.insert(0, os.path.abspath("../gemgis/"))
28+
#sys.path.insert(0, os.path.abspath("../../gemgis/"))
2929

3030
# The full version, including alpha/beta/rc tags
3131

docs/getting_started/tutorial/68_Creating_Finite_Faults_with_GemGIS.ipynb

Lines changed: 73 additions & 80 deletions
Large diffs are not rendered by default.

environment.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
1+
# Requirements as of October 2023
12
name: gemgis_env
23
channels:
34
- conda-forge
45
dependencies:
56
- python>=3.10
6-
- geopandas
7-
- rasterio
8-
- pyvista
9-
- pip
10-
- pip:
11-
- gemgis
7+
# geopandas will also install numpy, pandas, shapely, fiona, and pyproj
8+
- geopandas>=0.14.0
9+
# rasterio will also install affine
10+
- rasterio>=1.3.8
11+
# pyvista also install pooch and matplotlib
12+
- pyvista>=0.42.2
13+
- gemgis>=1.1

environment_dev.yml

Lines changed: 21 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,37 +2,30 @@ name: gemgis_dev_env
22
channels:
33
- conda-forge
44
dependencies:
5-
#- python>=3.10
6-
#- geopandas=0.13.2
7-
#- rasterio=1.3.8
8-
#- pyvista=0.39.1
5+
- python>=3.10
6+
# geopandas will also install numpy, pandas, shapely, fiona, and pyproj
7+
- geopandas>=0.14.0
8+
# rasterio will also install affine
9+
#- rasterio>=1.3.8 will be installed through rioxarray
10+
# pyvista also install pooch and matplotlib
11+
#- pyvista>=0.42.2 will be installed through pvgeo
12+
- gemgis>=1.1
13+
- rioxarray
14+
- scipy
15+
- owslib
16+
- scikit-image
17+
- mplstereonet
18+
- PyPDF2
19+
- xmltodict
20+
- geopy
21+
- scikit-learn
22+
- tqdm
23+
- requests
24+
- pooch<1.5.0
925
- pip
1026
- pip:
11-
- gempy==2.3
12-
- rasterio==1.3.8
13-
- geopandas==0.13.2
14-
- pyvista
15-
- shapely
16-
- fiona
17-
- pyproj
18-
- gemgis
19-
- matplotlib
20-
- pandas
21-
- scipy
22-
- owslib
23-
- xarray
24-
- scikit-image
25-
- rioxarray
26-
- mplstereonet
27-
- PyPDF2
28-
- xmltodict
29-
- geopy
30-
- scikit-learn
31-
- tqdm
32-
- requests
27+
- gempy>=2.3
3328
- PVGeo
34-
- pooch<1.5.0
35-
- gemgis==1.0.11
3629
- pyqt5
3730
- nbsphinx
3831
- sphinx_markdown_tables

gemgis/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2458,7 +2458,7 @@ def open_mpk(path_in: str):
24582458
"""
24592459
# Trying to import py7zr but returning error if py7zr is not installed
24602460
try:
2461-
import py7zr as gp
2461+
import py7zr
24622462
except ModuleNotFoundError:
24632463
raise ModuleNotFoundError(
24642464
'py7zr package is not installed. Use pip install py7zr to install the latest version')

pyproject.toml

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ requires = ["setuptools>=68.1.2",
44
build-backend = "setuptools.build_meta"
55

66
[tool.setuptools]
7-
package-dir = { "" = "gemgis" }
7+
packages = ["gemgis"]
88

99
[project]
1010
name = "GemGIS"
@@ -34,11 +34,44 @@ classifiers = [
3434
'License :: OSI Approved :: GNU General Public License v3 (GPLv3)',
3535
'Operating System :: OS Independent',
3636
]
37+
# These dependencies are needed to import GemGIS successfully
38+
# These dependencies will automatically install other packages like numpy, pandas or matplotlib
3739
dependencies = [
3840
'geopandas',
3941
'rasterio',
4042
'pyvista',
4143
]
44+
45+
[project.optional-dependencies]
46+
optionals = [
47+
'scipy',
48+
'PyPDF2',
49+
'tqdm',
50+
'gempy',
51+
'pvgeo',
52+
'xml',
53+
'scikit-image',
54+
'xmltodict',
55+
'geopy',
56+
'scikit-learn',
57+
'py7zr',
58+
'segysak',
59+
'rioxarray',
60+
'tqdm',
61+
'mplstereonet',
62+
'xarray',
63+
'owslib',
64+
'requests',
65+
'urllib'
66+
]
67+
68+
build = [
69+
'setuptools',
70+
'wheel',
71+
'twine',
72+
'build'
73+
]
74+
4275
[project.urls]
4376
Documentation = 'https://gemgis.readthedocs.io/'
4477
Home = 'https://gemgis.readthedocs.io/'

requirements.txt

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
# Requirements should be installed via conda-forge
1+
# Requirements as of October 2023
22

3-
geopandas
4-
rasterio
5-
pyvista
3+
# geopandas will also install numpy, pandas, shapely, fiona, and pyproj
4+
geopandas>=0.14.0
5+
6+
# rasterio will also install affine
7+
rasterio>=1.3.8
8+
9+
# pyvista also install pooch and matplotlib
10+
pyvista>=0.42.2

requirements_optional.txt

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
11
# Optional dependencies
22

3-
gempy>=2.3
4-
owslib
5-
geopy
6-
matplotlib
3+
scipy
74
PyPDF2
85
tqdm
6+
gempy
7+
pvgeo
8+
xml
99
scikit-image
10-
scikit-learn
1110
xmltodict
12-
scipy
13-
mplstereonet
11+
geopy
12+
scikit-learn
13+
py7zr
14+
segysak
1415
rioxarray
15-
pytest
16-
numpy
17-
pandas
18-
shapely
19-
affine
16+
tqdm
17+
mplstereonet
18+
xarray
2019
owslib
21-
pooch<1.5.0
22-
pytest-cov
23-
pyqt5
20+
requests
21+
urllib

0 commit comments

Comments
 (0)