Package: pygmi
PyGMI stands for Python Geoscience Modelling and Interpretation. It is a modelling and interpretation suite aimed at magnetic, gravity, remote sensing and other datasets.PyGMI is developed at theCouncil for Geoscience(Geological Survey of South Africa).It includes:Magnetic and Gravity 3D forward modelling.Cluster Analysis, including use of scikit-learn libraries.Routines for cutting, reprojecting and doing simple modifications to data.Convenient display of data using pseudo-color, ternary and sunshaded representation.MT processing and 1D inversion using MTpy.Gravity processing.Seismological functions for SEISAN data.Remote sensing ratios and improved imports.It is released under theGnu General Public License version 3.0The PyGMIWikipages, include installation and full usage!The latest release version can be foundhere.You may need to install theMicrosoft Visual C++ Redistributable for Visual Studio 2015, 2017 and 2019.If you have any comments or queries, you can contact the author either throughGitHubor via email atpcole@geoscience.org.zaRequirementsPyGMI will run on both Windows and Linux. It should be noted that the main development is done in Python 3.11 on Windows.PyGMI should still work with Python 3.9 and Python 3.10.PyGMI is developed and has been tested with the following libraries in order to function:python 3.11.6discretize 0.10.0fiona 1.9.5gdal 3.8.2geopandas 0.14.2matplotlib 3.8.2mtpy 1.1.5natsort 8.4.0numba 0.58.1numexpr 2.8.8numpy 1.26.3openpyxl 3.1.2pandas 2.1.4psutil 5.9.7pyogrio 0.7.2pyopengl 3.1.7pyproj 3.6.1PyQt5 5.15.10pytest 7.4.4rasterio 1.3.9scikit-image 0.22.0scikit-learn 1.3.2scipy 1.11.3shapely 2.0.2shapelysmooth 0.1.1SimPEG 0.20.0.post2InstallationGeneral (Not Anaconda)The easiest way to install pygmi if you are working in a python environment is to use the pip command as follows:pip install pygmiThis will download pygmi from PyPI and install it within your python repository. Depending on your operating system, and which libraries you already have installed, you may need to follow instructions in sections below. Please note the use of pip when installing PyGMI may cause Anaconda installations to break. Anaconda users should follow the instructions below.Running pygmi can be now done at the command prompt as follows:pygmiIf you are in python, you can run PyGMI by using the following commands:from pygmi.main import mainmain()If you prefer not to install pygmi as a library, download the source code and execute the following command to run it manually:python quickstart.pyWindows UsersInstallers are available in64-bitAlternatively, you can use the instructions above to run PyGMI with your local python installation. You may need to install some dependencies using downloaded binaries, because of compilation requirements. Therefore, if you do get an error, you can try installing precompiled binaries before installing PyGMI.Examples of binaries you may need to get are:numexprnumballvmliteGDALdiscretizefionaThey can be obtained from thewebsiteby Christoph Gohlke.LinuxLinux normally comes with python installed, but the additional libraries will still need to be installed.Typically, packages can be installed using pip. The process is as follows:sudo apt-get install pipsudo apt-get install gdal-binsudo apt-get install libgdal-devpip install cythonpip install numpypip install pygmiAnacondaAnaconda users are advised not to use pip since it can break PyQt5. However, one package is installed only by pip, so a Conda environment should be created.The process to install is as follows:conda create -n pygmi python=3.10conda activate pygmiconda config –add channels conda-forgeconda config –set channel_priority flexibleconda install pyqtconda install numpyconda install scipyconda install matplotlibconda install psutilconda install numexprconda install pandasconda install rasterioconda install geopandasconda install numbaconda install natsortconda install scikit-learnconda install scikit-imageconda install pyopenglconda install simpegconda install shapelysmoothconda install pyogrioconda install openpyxlpip install mtpyconda update –allOnce this is done, download pygmi, extract (unzip) it to a directory, and run it from its root directory with the following command:python quickstart.py