Package: hsi-wizard
HSI-WizardThe goal is to set up a straightforward environment for hyperspectral analysis. The HIS-Wizard provides a range of useful tools for this purpose, spanning from basic spectral analysis to advanced methods utilizing artificial intelligence.FeaturesDataCube ClassSpectral plotting functionClusteringSpectral AnalyticsMaldi AnalyticsMerge Spectral DataHyperspectral ImagingRequirementsPython>3.10InstallationpipWhen utilizing pip, hsi-wizard releases are accessible in the form of source packages and binary wheels. Before proceeding with the installation of hsi-wizard and its prerequisites, ensure that your pip, setuptools, and wheel are updated to the latest versionspip install hsi_wizCompile from sourceAn alternative method for installing HSIWizard involves cloning its GitHub repository and compiling it from source. This approach is commonly chosen when modifications to the code are desired. It is essential to have a development environment set up, which should include a Python distribution with header files, a compiler, as well as installations of pip and git.python -m pip install -U pip setuptools wheel            # install/update build tools
git clone https://github.com/BlueSpacePotato/hsi-wizard  # clone hsi-wizard
cd hsi-wizard                                            # navigate into dir
python -m venv .env                                      # create environment in .env
source .env/bin/activate                                 # activate virtual env
pip install -r requirements.txt                          # install requirements
pip install --no-build-isolation --editable .            # compile and install hsi-wizardDocumentationClick here for Docs!The Documentation is available as readthedocs project. Build withsphinxand thesphinx_rtd_theme.The Git Structuredocs/data for the sphinx/readthedocs implementationresources/for storing images and sample data and equivalentwizard/the source code for thehsi-wizardpython-lib that can be used as stand aloneworkflows/.yml-files for autobuild etcCode Philosophykeep things simpleimplement only the smallest amount of code, to solve a problemdon't make up, no existing problemstry to solve problems the easiest way firstbuild reliability codewrite usefull comandsDefinitionsTo build a clean code and communicate the ideas the right way, we need to define some basic understandings.DataCubeA Datacube is a 3D array with shapevxyxandyvalues describe the number of pixels in each directionvvalues (often called λ in papers) describe the information deapth of the spectrum, commanly as measured counts.from matplotlib import pyplot as plt
import numpy as np

len_v = 50
len_x = 5
len_y = 6

# define empty array with given shape
data_cube = dc.empty(shape=(len_v, len_x, len_y))

# get the spectru for a single pixel and plot it
spectrum = data_cube[:, 3, 3]
plt.plot(spectrum)
plt.show()

# show 2d image for channel 3
img = datacube[3]
plt.imshow(img_2d)
plt.show()Diffrence read and loadAsloadingfunction is used to import already processed data. For example if you want to load in an already existing numpy array. Areadfunction on the other hand, reads dedicate files, like a*.csvor*.fsmfile.Pre-Processing LevelBased on an Idea fromDOILevel 0: Data is captured directly from sensorLevel 1: Data is processed in a easy wayLevel 2: Data is hardly processedTo Dosbetter hyperparameter tuning with evolsourceR-support with patsysourcebetter template-creatormerge function for multiple specsspec appending functionsave file as nrrdChangelogThe changelog will be added if the beta version is fine and runs stableAcknolagementThanks toshopifyproviding a free logo build with the freehatchfullogo-generator.Icons made byGood Warefromwww.flaticon.com