chemotools 0.0.23__py3-none-any.whl → 0.0.24__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- chemotools/datasets/__init__.py +2 -0
- chemotools/datasets/_base.py +52 -0
- chemotools/datasets/data/__init__.py +0 -0
- chemotools/datasets/data/fermentation_hplc.csv +35 -0
- chemotools/datasets/data/fermentation_spectra.csv +1630 -0
- chemotools/datasets/data/train_hplc.csv +22 -0
- chemotools/datasets/data/train_spectra.csv +22 -0
- chemotools/scatter/extended_multiplicative_scatter_correction.py +5 -0
- {chemotools-0.0.23.dist-info → chemotools-0.0.24.dist-info}/METADATA +2 -1
- {chemotools-0.0.23.dist-info → chemotools-0.0.24.dist-info}/RECORD +14 -6
- {chemotools-0.0.23.dist-info → chemotools-0.0.24.dist-info}/WHEEL +1 -1
- tests/test_datasets.py +30 -0
- {chemotools-0.0.23.dist-info → chemotools-0.0.24.dist-info}/LICENSE +0 -0
- {chemotools-0.0.23.dist-info → chemotools-0.0.24.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,52 @@
|
|
1
|
+
import pandas as pd
|
2
|
+
import os
|
3
|
+
|
4
|
+
PACKAGE_DIRECTORY = os.path.dirname(os.path.abspath(__file__))
|
5
|
+
|
6
|
+
|
7
|
+
def load_fermentation_train():
|
8
|
+
"""
|
9
|
+
Loads the training data of the fermentation dataset. This data corresponds to a synthetic dataset measured
|
10
|
+
off-line. This dataset is designed to represent the variability of real fermentation data.
|
11
|
+
|
12
|
+
Returns
|
13
|
+
-------
|
14
|
+
train_spectra: pd.DataFrame A pandas DataFrame containing the synthetic spectra measured to train the model.
|
15
|
+
train_hplc: pd.DataFrame A pandas DataFrame containing the corresponding reference measurements analyzed with HPLC.
|
16
|
+
|
17
|
+
References
|
18
|
+
-------
|
19
|
+
- Cabaneros Lopez Pau, Udugama Isuru A., Thomsen Sune Tjalfe, Roslander Christian, Junicke Helena,
|
20
|
+
Mauricio Iglesias Miguel, Gernaey Krist V. Transforming data into information:
|
21
|
+
A parallel hybrid model for real-time state estimation in lignocellulose ethanol fermentations.
|
22
|
+
"""
|
23
|
+
train_spectra = pd.read_csv(PACKAGE_DIRECTORY + "/data/train_spectra.csv")
|
24
|
+
train_spectra.columns = train_spectra.columns.astype(float)
|
25
|
+
train_hplc = pd.read_csv(PACKAGE_DIRECTORY + "/data/train_hplc.csv")
|
26
|
+
|
27
|
+
return train_spectra, train_hplc
|
28
|
+
|
29
|
+
|
30
|
+
def load_fermentation_test():
|
31
|
+
"""
|
32
|
+
Loads the testing data of the fermentation dataset. This data corresponds to real fermentation data measured
|
33
|
+
on-line during a fermentation process.
|
34
|
+
|
35
|
+
Returns
|
36
|
+
-------
|
37
|
+
test_spectra: pd.DataFrame A pandas DataFrame containing the on-line spectra measured to train the model.
|
38
|
+
test_hplc: pd.DataFrame A pandas DataFrame containing the corresponding HPLC measurements.
|
39
|
+
|
40
|
+
References
|
41
|
+
-------
|
42
|
+
- Cabaneros Lopez Pau, Udugama Isuru A., Thomsen Sune Tjalfe, Roslander Christian, Junicke Helena,
|
43
|
+
Mauricio Iglesias Miguel, Gernaey Krist V. Transforming data into information:
|
44
|
+
A parallel hybrid model for real-time state estimation in lignocellulose ethanol fermentations.
|
45
|
+
"""
|
46
|
+
fermentation_spectra = pd.read_csv(
|
47
|
+
PACKAGE_DIRECTORY + "/data/fermentation_spectra.csv"
|
48
|
+
)
|
49
|
+
fermentation_spectra.columns = fermentation_spectra.columns.astype(float)
|
50
|
+
fermentation_hplc = pd.read_csv(PACKAGE_DIRECTORY + "/data/fermentation_hplc.csv")
|
51
|
+
|
52
|
+
return fermentation_spectra, fermentation_hplc
|
File without changes
|
@@ -0,0 +1,35 @@
|
|
1
|
+
time,glucose,xylose,acetic_acid,ethanol,furfural
|
2
|
+
0,40.41567094,21.25891737,3.375666211,0,0.553330768
|
3
|
+
0.666666667,40.6426422,21.42072789,3.375666211,0,0.553330768
|
4
|
+
1.833333333,40.72109326,21.63050368,3.346897389,0,0.412503821
|
5
|
+
2.733333333,40.42979778,21.63156316,3.349886358,0,0.382085053
|
6
|
+
3.55,40.34579016,21.74685316,3.370435516,0.360890316,0.358981042
|
7
|
+
4.7,40.31254499,21.89826158,3.402566926,0.436324842,0.306313389
|
8
|
+
5.683333333,40.00702848,21.94189263,3.430775316,0.515675368,0.2689518
|
9
|
+
6.7,44.11275969,24.45178579,3.839703558,0.770215368,0.313648263
|
10
|
+
7.466666667,39.35700539,22.10697789,3.513532379,0.794948,0.214576358
|
11
|
+
8.65,37.82584406,21.89922474,3.546784653,1.267959579,0.133798326
|
12
|
+
9.616666667,37.13786685,21.83093684,3.530905758,1.540224632,0.083228053
|
13
|
+
10.58333333,35.57006992,21.78701684,3.552762589,2.175853263,0.046751968
|
14
|
+
11.63333333,35.63175713,23.37218211,3.827560874,3.453912,0.021523484
|
15
|
+
12.7,29.36546668,21.52484526,3.567520621,4.607689263,0.010342389
|
16
|
+
13.7,29.23747749,25.43883,4.229390316,8.117043579,0.009108758
|
17
|
+
14.98333333,22.25231915,25.54458474,4.272356737,11.34403368,0.007732674
|
18
|
+
15.98333333,11.03654831,21.40984421,3.678112453,12.93475411,0.005611895
|
19
|
+
16.98333333,2.137485389,20.18856,3.528290411,15.62813768,0.0049998
|
20
|
+
17.88333333,0.237707663,18.67698,3.697727558,18.753724,0.005131168
|
21
|
+
18.96666667,0.192595947,15.48228158,3.535762832,18.03833263,0
|
22
|
+
19.11666667,0.192407589,14.19184263,3.724815084,20.602076,0
|
23
|
+
20.88333333,0,11.58024,3.422368842,19.18819389,0
|
24
|
+
21.88333333,0,9.929483684,3.384633116,20.09526316,0
|
25
|
+
22.88333333,0,8.671503158,3.436566442,19.95572989,0
|
26
|
+
23.91666667,0,7.349183684,3.425544621,20.58187768,0
|
27
|
+
25.68333333,0,6.200136316,3.411347021,20.85084505,0
|
28
|
+
26.61666667,0,5.242468421,3.383138632,21.04520232,0
|
29
|
+
27.55,0,3.309699474,3.382765011,21.86673789,0
|
30
|
+
28.68333333,0,2.741532632,3.402566926,21.94361516,0
|
31
|
+
29.66666667,0,2.233852105,3.756012442,24.06423221,0
|
32
|
+
30.68333333,0,1.633804737,3.402193305,22.53039684,0
|
33
|
+
31.61666667,0,1.533154737,3.421995221,21.51780168,0
|
34
|
+
32.63333333,0,1.230434211,3.362215853,21.90507347,0
|
35
|
+
33.88333333,0,0.967684737,3.370061895,22.65715158,0
|