pyspectrace 2.0.0__tar.gz

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.
Files changed (133) hide show
  1. pyspectrace-2.0.0/LICENSE +178 -0
  2. pyspectrace-2.0.0/PKG-INFO +104 -0
  3. pyspectrace-2.0.0/README.md +80 -0
  4. pyspectrace-2.0.0/pyproject.toml +38 -0
  5. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/Communication/__init__.py +0 -0
  6. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/Communication/communicationcontrol.py +34 -0
  7. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/Info/__init__.py +0 -0
  8. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/Saving/__init__.py +0 -0
  9. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/Saving/savingcontrol.py +190 -0
  10. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/__init__.py +0 -0
  11. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Acquisition/acquisitioncontrol.py +10 -0
  12. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Plotting/Sensorgramcontrol/__init__.py +6 -0
  13. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Plotting/Sensorgramcontrol/sensorgramcontrol.py +192 -0
  14. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Plotting/Spectrumcontrol/spectrumcontrol.py +99 -0
  15. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Plotting/__init__.py +0 -0
  16. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Plotting/plottingcontrol.py +11 -0
  17. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/Shift/PolynomialFitting/polynomialfittingcontrol.py +126 -0
  18. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftPeak/GaussianPeakFitting/gaussianpeakfittingcontrol.py +167 -0
  19. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftPeak/LorentzianPeakFitting/lorentzianpeakfittingcontrol.py +158 -0
  20. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftPeak/PolyPeakFitting/polypeakfittingcontrol.py +125 -0
  21. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftPeak/PolynomialPeakFitting/polynomialpeakfittingcontrol.py +235 -0
  22. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftPeak/__init.py +0 -0
  23. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftWidthPeak/GaussianWidthPeakFitting/gaussianwidthpeakfittingcontrol.py +140 -0
  24. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftWidthPeak/LorentzianWidthPeakFitting/lorentzianwidthpeakfittingcontrol.py +139 -0
  25. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftWidthPeak/PolynomialWidthPeakFitting/polynomialwidthpeakfittingcontrol.py +140 -0
  26. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/ShiftWidthPeak/__init__.py +0 -0
  27. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/__init__.py +0 -0
  28. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Processing/processingcontrol.py +21 -0
  29. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/BaselineSpectrum/__init__.py +0 -0
  30. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/BaselineSpectrum/baselinespectrumcontrol.py +56 -0
  31. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/NormalizationSpectrum/BrightSpectrum/__init__.py +0 -0
  32. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/NormalizationSpectrum/BrightSpectrum/brightspectrumcontrol.py +65 -0
  33. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/NormalizationSpectrum/DarkSpectrum/__init__.py +0 -0
  34. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/NormalizationSpectrum/DarkSpectrum/darkspectrumcontrol.py +66 -0
  35. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/NormalizationSpectrum/normalizationspectrumcontrol.py +28 -0
  36. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/__init__.py +0 -0
  37. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/Reference/referencecontrol.py +129 -0
  38. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/__init__.py +0 -0
  39. pyspectrace-2.0.0/src/pyspectrace/Control/Configuration/configurationcontrol.py +17 -0
  40. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/File/filecontrol.py +8 -0
  41. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/SDK/__init__.py +1 -0
  42. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/SDK/sdkcontrol.py +68 -0
  43. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/Tool/Convert/convertcontrol.py +205 -0
  44. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/Tool/Plot3D/plot3dcontrol.py +186 -0
  45. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/Tool/PlotSensorgram/plotsensorgramcontrol.py +68 -0
  46. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/Tool/toolcontrol.py +26 -0
  47. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/__init__.py +0 -0
  48. pyspectrace-2.0.0/src/pyspectrace/Control/Menusbar/menusbarcontrol.py +14 -0
  49. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/Sensorgram/__init__.py +0 -0
  50. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/Sensorgram/sensorgramcontrol.py +25 -0
  51. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/Spectrum/__init__.py +0 -0
  52. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/Spectrum/spectrumcontrol.py +17 -0
  53. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/__init__.py +0 -0
  54. pyspectrace-2.0.0/src/pyspectrace/Control/Plotting/plottingcontrol.py +11 -0
  55. pyspectrace-2.0.0/src/pyspectrace/Control/__init__.py +0 -0
  56. pyspectrace-2.0.0/src/pyspectrace/Control/maincontrol.py +818 -0
  57. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Communication/__init__.py +0 -0
  58. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Communication/communicationlayout.py +94 -0
  59. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Info/__init__.py +0 -0
  60. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Info/infolayout.py +27 -0
  61. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/__init__.py +0 -0
  62. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/iconrecord.png +0 -0
  63. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/iconrecording.png +0 -0
  64. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/iconrecordoff.png +0 -0
  65. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/iconrecordon.png +0 -0
  66. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/Saving/savinglayout.py +223 -0
  67. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/__init__.py +0 -0
  68. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Acquisition/acquisitionlayout.py +52 -0
  69. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Plotting/Sensorgram/sensorgramlayout.py +99 -0
  70. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Plotting/Spectrum/spectrumlayout.py +81 -0
  71. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Plotting/__init__.py +0 -0
  72. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Plotting/plottinglayout.py +24 -0
  73. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/Shift/PolynomialFitting/polynomialfittinglayout.py +231 -0
  74. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/Shift/shiftlayout.py +17 -0
  75. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/GaussianPeakFitting/gaussianpeakfittinglayout.py +230 -0
  76. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/LorentzianPeakFitting/lorentzianpeakfittinglayout.py +229 -0
  77. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/PolyPeakFitting/polypeakfittinglayout.py +246 -0
  78. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/PolynomialPeakFitting/polynomialpeakfittinglayout.py +259 -0
  79. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/__init__.py +0 -0
  80. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeak/shiftpeaklayout.py +28 -0
  81. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/GaussianPeakWidthFitting/gaussianpeakwidthfittinglayout.py +214 -0
  82. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/LorentzianPeakWidthFitting/lorentzianpeakwidthfittinglayout.py +215 -0
  83. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/PolynomialPeakWidthFitting/__init__.py +0 -0
  84. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/PolynomialPeakWidthFitting/polynomialpeakwidthfittinglayout.py +232 -0
  85. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/__init__.py +0 -0
  86. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/ShiftPeakWidth/shiftpeakwidthlayout.py +24 -0
  87. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/__init__.py +0 -0
  88. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Processing/processinglayout.py +39 -0
  89. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Reference/BaselineSpectrum/baselinespectrumlayout.py +90 -0
  90. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Reference/NormalizationSpectrum/normalizationspectrumlayout.py +104 -0
  91. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Reference/__init__.py +0 -0
  92. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/Reference/referencelayout.py +28 -0
  93. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/__init__.py +0 -0
  94. pyspectrace-2.0.0/src/pyspectrace/Layout/Configuration/configurationlayout.py +24 -0
  95. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/File/__init__.py +0 -0
  96. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/File/exitlayout.py +6 -0
  97. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/File/showrecordcontrollerlayout.py +3 -0
  98. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/SDK/__init__.py +1 -0
  99. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/SDK/sdklayout.py +11 -0
  100. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/Tool/Convert/convertlayout.py +7 -0
  101. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/Tool/Plot3D/plot3dlayout.py +8 -0
  102. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/Tool/PlotSensorgram/plotsensorgramlayout.py +7 -0
  103. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/Tool/toollayout.py +10 -0
  104. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/__init__.py +0 -0
  105. pyspectrace-2.0.0/src/pyspectrace/Layout/Menusbar/menusbarlayout.py +54 -0
  106. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/Sensorgram/__init__.py +0 -0
  107. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/Sensorgram/sensorgramlayout.py +610 -0
  108. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/Spectrum/__init__.py +0 -0
  109. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/Spectrum/spectrumlayout.py +621 -0
  110. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/__init__.py +0 -0
  111. pyspectrace-2.0.0/src/pyspectrace/Layout/Plotting/plottinglayout.py +13 -0
  112. pyspectrace-2.0.0/src/pyspectrace/Layout/__init__.py +0 -0
  113. pyspectrace-2.0.0/src/pyspectrace/Layout/mainlayout.py +193 -0
  114. pyspectrace-2.0.0/src/pyspectrace/Model/AvanterSpectrometer/HelloSpectrometer.py +53 -0
  115. pyspectrace-2.0.0/src/pyspectrace/Model/AvanterSpectrometer/avantesspectrometermodel.py +171 -0
  116. pyspectrace-2.0.0/src/pyspectrace/Model/AvanterSpectrometer/avaspec.py +571 -0
  117. pyspectrace-2.0.0/src/pyspectrace/Model/CNILaserSpectrometer/cnilaserspectrometermodel.py +103 -0
  118. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/Oceandirect/OceanDirectAPI.py +3927 -0
  119. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/Oceandirect/__init__.py +0 -0
  120. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/Oceandirect/od_logger.py +56 -0
  121. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/Oceandirect/sdk_properties.py +35 -0
  122. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/__init__.py +0 -0
  123. pyspectrace-2.0.0/src/pyspectrace/Model/OceanSpectrometer/oceanspectrometermodel.py +88 -0
  124. pyspectrace-2.0.0/src/pyspectrace/Model/RecordSpectrometer/recordspectrometermodel.py +280 -0
  125. pyspectrace-2.0.0/src/pyspectrace/Model/SimulatorSpectrometer/__init__.py +0 -0
  126. pyspectrace-2.0.0/src/pyspectrace/Model/SimulatorSpectrometer/simulatorspectrometermodel.py +308 -0
  127. pyspectrace-2.0.0/src/pyspectrace/Model/VirtualSpectrometer/__init__.py +0 -0
  128. pyspectrace-2.0.0/src/pyspectrace/Model/VirtualSpectrometer/virtualspectrometermodel.py +107 -0
  129. pyspectrace-2.0.0/src/pyspectrace/Model/__init__.py +0 -0
  130. pyspectrace-2.0.0/src/pyspectrace/Model/mainmodel.py +84 -0
  131. pyspectrace-2.0.0/src/pyspectrace/Model/sdkmanager.py +60 -0
  132. pyspectrace-2.0.0/src/pyspectrace/__init__.py +0 -0
  133. pyspectrace-2.0.0/src/pyspectrace/main.py +20 -0
@@ -0,0 +1,178 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+
@@ -0,0 +1,104 @@
1
+ Metadata-Version: 2.4
2
+ Name: pyspectrace
3
+ Version: 2.0.0
4
+ Summary: **PySpecTrace** is an open-source, Python-based graphical user interface (GUI) designed for real-time UV-visible-NIR spectroscopy data analysis. It addresses the limitations of proprietary spectrometer software by providing advanced, customizable, and real-time spectral tracking and analysis tools suitable for a wide range of scientific disciplines
5
+ Author-email: Iwan Darmadi <iwan.darmadi@alumni.ui.ac.id>
6
+ License-Expression: Apache-2.0
7
+ License-File: LICENSE
8
+ Classifier: License :: OSI Approved :: Apache Software License
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: Programming Language :: Python :: 3.9
11
+ Classifier: Programming Language :: Python :: 3.10
12
+ Classifier: Programming Language :: Python :: 3.11
13
+ Classifier: Programming Language :: Python :: 3.12
14
+ Requires-Python: <3.13,>=3.9
15
+ Requires-Dist: matplotlib==3.9.4
16
+ Requires-Dist: numpy==1.26.4
17
+ Requires-Dist: pandas==2.3.3
18
+ Requires-Dist: pyqt5==5.15.11
19
+ Requires-Dist: pyqtgraph==0.13.7
20
+ Requires-Dist: scipy==1.13.1
21
+ Requires-Dist: seabreeze==2.11.0
22
+ Requires-Dist: seatease==0.4.0
23
+ Description-Content-Type: text/markdown
24
+
25
+ # PySpecTrace: Python-based Graphical User Interface (GUI) for Real-time UV-Vis-NIR Spectroscopy Analysis
26
+
27
+ **PySpecTrace** is an open-source, Python-based graphical user interface (GUI) designed for real-time UV-visible-NIR spectroscopy data analysis. It addresses the limitations of proprietary spectrometer software by providing advanced, customizable, and real-time spectral tracking and analysis tools suitable for a wide range of scientific disciplines.
28
+
29
+ ![PySpecTrace Application](https://github.com/anamsigit/pyspectrace/blob/main/GUI_snapshot.png?raw=true)
30
+
31
+ ## Installation
32
+ Open a terminal or Command Prompt
33
+ then run the following command to install the latest version from PyPI:
34
+ ```
35
+ pip install pyspectrace
36
+ ```
37
+
38
+ ### Run the Application
39
+ After installation is complete, start the program with open terminal and write:
40
+ ```
41
+ pyspectrace
42
+ ```
43
+
44
+ ### Spectrometer SDK Setup
45
+ To connect the software with supported spectrometers, you must manually provide the required SDK files (DLLs/shared libraries). These SDKs are proprietary and must be obtained directly from the hardware manufacturers.
46
+
47
+ You can add SDK files from the application menu:
48
+ 1. Open PySpecTrace.
49
+ 2. Click menu bar ```SDK```.
50
+ 3. Choose the vendor: ```Ocean Optics```, ```CNI Laser```, or ```Avantes```.
51
+ 4. Select ```Add ... DLL``` and choose the required ```.dll``` file.
52
+ 5. Close PySpecTrace then run again
53
+
54
+ PySpecTrace stores user-provided SDK files in the user data directory. This keeps the PyPI package free from proprietary SDK files.
55
+
56
+ ### Requirements
57
+ * Python 3.9 – 3.12
58
+
59
+ ***Notes for Avantes Spectrometer***: If the spectrometer is still not detected after placing the SDK, please Install the official Avantes interface software from https://www.avantes.com/products/software/
60
+
61
+ > Detailed steps for running documented in the Manual: [PySpecTrace_Manual.pdf](https://github.com/anamsigit/pyspectrace/blob/main/PySpecTrace_Manual.pdf)
62
+
63
+ _If you encounter any issues or need assistance, we will do our best to help. Please feel free to contact us via the **Corresponding Contact**_
64
+
65
+
66
+ ## Extra Documentation
67
+ - **Zenodo archive:** [doi.org/10.5281/zenodo.18920460](https://doi.org/10.5281/zenodo.18920460)
68
+ - **Repository:** [https://github.com/anamsigit/pyspectrace](https://github.com/anamsigit/pyspectrace)
69
+ - **Supporting information:** [PySpecTrace_SI.pdf](https://github.com/anamsigit/pyspectrace/blob/main/PySpecTrace_SI.pdf)
70
+ - **Demonstration video:** [Google drive](https://drive.google.com/file/d/1Tj6Fig017nFhzMavVcG9cRoBS5tbMKVn/view?usp=sharing)
71
+
72
+
73
+
74
+ ## Key Features
75
+ - **Real-time spectral visualization:** Enables immediate monitoring of spectral changes during experiments.
76
+ - **Dynamic spectral tracing and peak tracking:** Utilizes adaptive fitting routines to identify and track spectral features live.
77
+ - **Flexible configuration:** User-friendly GUI includes panels for spectrometer connection, settings, data display, and analysis.
78
+ - **Spectral post-processing:** Offers robust data analysis capabilities for in-depth interpretation.
79
+ - **Spectrometer Simulator:** Supports testing without physical hardware, facilitating development and training.
80
+ - **Modular and adaptable:** Compatible with any spectrometer via appropriate driver interfaces; easily customizable for various experimental needs.
81
+
82
+ ## Architecture
83
+ - Built on a **Model-View-Presenter (MVP)** pattern for maintainability and scalability.
84
+ - Uses popular Python libraries including **PyQt5, NumPy, SciPy, Pandas, Matplotlib, and PyQtGraph**.
85
+ - This project has been tested with **Python 3.9.13**.
86
+
87
+ ## List of working spectrometers
88
+ PySpecTrace has been tested and working seamlessly with these commercial spectrometers (on Windows OS). Testing was performed using some instruments available from several research laboratories: Photonics Research Center of Indonesia; Chemistry Dept. of Chulalongkorn University; Electrical Eng. Dept. of Universiti Teknologi Malaysia; IMRAN, Tohoku University, Physics Dept. of Universitas Indonesia.
89
+
90
+ | Ocean Optics | Avantes | CNI |
91
+ |-----------------------|------------------------------|--------------|
92
+ | Maya PRO2000 | AvaSpec-ULS4096CL-EVO | Aurora 4000 |
93
+ | HR 4000CG-UV-NIR | AvaSpec-2048-USB2 | |
94
+ | USB4000 | | |
95
+
96
+ Please add to the list if you have found that it works in your spectrometer. It will be a nice information for new user.
97
+
98
+ ## Corresponding contact
99
+ - Feel free to contact us via Iwan Darmadi (email:iwan.darmadi@alumni.ui.ac.id) for technical support, bug reports, feature requests, or questions regarding PySpecTrace.
100
+
101
+
102
+ ---
103
+
104
+
@@ -0,0 +1,80 @@
1
+ # PySpecTrace: Python-based Graphical User Interface (GUI) for Real-time UV-Vis-NIR Spectroscopy Analysis
2
+
3
+ **PySpecTrace** is an open-source, Python-based graphical user interface (GUI) designed for real-time UV-visible-NIR spectroscopy data analysis. It addresses the limitations of proprietary spectrometer software by providing advanced, customizable, and real-time spectral tracking and analysis tools suitable for a wide range of scientific disciplines.
4
+
5
+ ![PySpecTrace Application](https://github.com/anamsigit/pyspectrace/blob/main/GUI_snapshot.png?raw=true)
6
+
7
+ ## Installation
8
+ Open a terminal or Command Prompt
9
+ then run the following command to install the latest version from PyPI:
10
+ ```
11
+ pip install pyspectrace
12
+ ```
13
+
14
+ ### Run the Application
15
+ After installation is complete, start the program with open terminal and write:
16
+ ```
17
+ pyspectrace
18
+ ```
19
+
20
+ ### Spectrometer SDK Setup
21
+ To connect the software with supported spectrometers, you must manually provide the required SDK files (DLLs/shared libraries). These SDKs are proprietary and must be obtained directly from the hardware manufacturers.
22
+
23
+ You can add SDK files from the application menu:
24
+ 1. Open PySpecTrace.
25
+ 2. Click menu bar ```SDK```.
26
+ 3. Choose the vendor: ```Ocean Optics```, ```CNI Laser```, or ```Avantes```.
27
+ 4. Select ```Add ... DLL``` and choose the required ```.dll``` file.
28
+ 5. Close PySpecTrace then run again
29
+
30
+ PySpecTrace stores user-provided SDK files in the user data directory. This keeps the PyPI package free from proprietary SDK files.
31
+
32
+ ### Requirements
33
+ * Python 3.9 – 3.12
34
+
35
+ ***Notes for Avantes Spectrometer***: If the spectrometer is still not detected after placing the SDK, please Install the official Avantes interface software from https://www.avantes.com/products/software/
36
+
37
+ > Detailed steps for running documented in the Manual: [PySpecTrace_Manual.pdf](https://github.com/anamsigit/pyspectrace/blob/main/PySpecTrace_Manual.pdf)
38
+
39
+ _If you encounter any issues or need assistance, we will do our best to help. Please feel free to contact us via the **Corresponding Contact**_
40
+
41
+
42
+ ## Extra Documentation
43
+ - **Zenodo archive:** [doi.org/10.5281/zenodo.18920460](https://doi.org/10.5281/zenodo.18920460)
44
+ - **Repository:** [https://github.com/anamsigit/pyspectrace](https://github.com/anamsigit/pyspectrace)
45
+ - **Supporting information:** [PySpecTrace_SI.pdf](https://github.com/anamsigit/pyspectrace/blob/main/PySpecTrace_SI.pdf)
46
+ - **Demonstration video:** [Google drive](https://drive.google.com/file/d/1Tj6Fig017nFhzMavVcG9cRoBS5tbMKVn/view?usp=sharing)
47
+
48
+
49
+
50
+ ## Key Features
51
+ - **Real-time spectral visualization:** Enables immediate monitoring of spectral changes during experiments.
52
+ - **Dynamic spectral tracing and peak tracking:** Utilizes adaptive fitting routines to identify and track spectral features live.
53
+ - **Flexible configuration:** User-friendly GUI includes panels for spectrometer connection, settings, data display, and analysis.
54
+ - **Spectral post-processing:** Offers robust data analysis capabilities for in-depth interpretation.
55
+ - **Spectrometer Simulator:** Supports testing without physical hardware, facilitating development and training.
56
+ - **Modular and adaptable:** Compatible with any spectrometer via appropriate driver interfaces; easily customizable for various experimental needs.
57
+
58
+ ## Architecture
59
+ - Built on a **Model-View-Presenter (MVP)** pattern for maintainability and scalability.
60
+ - Uses popular Python libraries including **PyQt5, NumPy, SciPy, Pandas, Matplotlib, and PyQtGraph**.
61
+ - This project has been tested with **Python 3.9.13**.
62
+
63
+ ## List of working spectrometers
64
+ PySpecTrace has been tested and working seamlessly with these commercial spectrometers (on Windows OS). Testing was performed using some instruments available from several research laboratories: Photonics Research Center of Indonesia; Chemistry Dept. of Chulalongkorn University; Electrical Eng. Dept. of Universiti Teknologi Malaysia; IMRAN, Tohoku University, Physics Dept. of Universitas Indonesia.
65
+
66
+ | Ocean Optics | Avantes | CNI |
67
+ |-----------------------|------------------------------|--------------|
68
+ | Maya PRO2000 | AvaSpec-ULS4096CL-EVO | Aurora 4000 |
69
+ | HR 4000CG-UV-NIR | AvaSpec-2048-USB2 | |
70
+ | USB4000 | | |
71
+
72
+ Please add to the list if you have found that it works in your spectrometer. It will be a nice information for new user.
73
+
74
+ ## Corresponding contact
75
+ - Feel free to contact us via Iwan Darmadi (email:iwan.darmadi@alumni.ui.ac.id) for technical support, bug reports, feature requests, or questions regarding PySpecTrace.
76
+
77
+
78
+ ---
79
+
80
+
@@ -0,0 +1,38 @@
1
+ [build-system]
2
+ requires = ["hatchling"]
3
+ build-backend = "hatchling.build"
4
+
5
+ [project]
6
+ name = "pyspectrace"
7
+ version = "2.0.0"
8
+ description = "**PySpecTrace** is an open-source, Python-based graphical user interface (GUI) designed for real-time UV-visible-NIR spectroscopy data analysis. It addresses the limitations of proprietary spectrometer software by providing advanced, customizable, and real-time spectral tracking and analysis tools suitable for a wide range of scientific disciplines"
9
+ readme = "README.md"
10
+ requires-python = ">=3.9,<3.13"
11
+ license = "Apache-2.0"
12
+
13
+ authors = [
14
+ { name = "Iwan Darmadi", email = "iwan.darmadi@alumni.ui.ac.id" }
15
+ ]
16
+
17
+ classifiers = [
18
+ "License :: OSI Approved :: Apache Software License",
19
+ "Programming Language :: Python :: 3",
20
+ "Programming Language :: Python :: 3.9",
21
+ "Programming Language :: Python :: 3.10",
22
+ "Programming Language :: Python :: 3.11",
23
+ "Programming Language :: Python :: 3.12",
24
+ ]
25
+
26
+ dependencies = [
27
+ "numpy==1.26.4",
28
+ "pandas==2.3.3",
29
+ "matplotlib==3.9.4",
30
+ "PyQt5==5.15.11",
31
+ "pyqtgraph==0.13.7",
32
+ "scipy==1.13.1",
33
+ "seatease==0.4.0",
34
+ "seabreeze==2.11.0"
35
+ ]
36
+
37
+ [project.gui-scripts]
38
+ pyspectrace = "pyspectrace.main:main"
@@ -0,0 +1,34 @@
1
+
2
+ class CommunicationControl:
3
+ def __init__(self, model, view):
4
+ self.model = model
5
+ self.view = view
6
+
7
+ self.delay_time = 250
8
+
9
+ self.view.configurationlayout.acquisitionlayout.communicationlayout.time_integration_button.clicked.connect(
10
+ lambda: self.integration_time_change(
11
+ self.view.configurationlayout.acquisitionlayout.communicationlayout.time_integration_spinbox.value()
12
+ )
13
+ )
14
+ self.view.configurationlayout.acquisitionlayout.communicationlayout.acquisitiondelay_button.clicked.connect(
15
+ lambda: self.acquisition_delay_change(
16
+ self.view.configurationlayout.acquisitionlayout.communicationlayout.acquisitiondelay_spinbox.value()
17
+ )
18
+ )
19
+
20
+ def mainloop(self):
21
+ self.acquire()
22
+
23
+ def acquire(self):
24
+ cumulative_plot = [self.model.acquire_spectrum()]
25
+ self.view.plottinglayout.spectrumlayout.num_spectrum = [None]
26
+ self.view.plottinglayout.spectrumlayout.plot_spectrum(cumulative_plot, cumulative_plot)
27
+
28
+ def integration_time_change(self, slot_integration_value):
29
+ self.model.set_integration_time(slot_integration_value)
30
+
31
+ def acquisition_delay_change(self, slot_delay_value):
32
+ self.delay_time = slot_delay_value
33
+ self.model.set_acquisition_delay(slot_delay_value)
34
+
@@ -0,0 +1,190 @@
1
+ import numpy as np
2
+ from datetime import datetime, timedelta
3
+ import os
4
+
5
+ class SavingControl:
6
+ def __init__(self, model, view):
7
+ self.model = model
8
+ self.view = view
9
+ self.mainpath = self.view.configurationlayout.acquisitionlayout.savinglayout.combined_path_text
10
+ self.processed_wavelengths = None
11
+ self.processed_intensities = None
12
+
13
+ self.raw_wavelengths = None
14
+ self.raw_intensities = None
15
+
16
+ self.stateresume = True
17
+
18
+ self.current_forprogress = 0
19
+ self.elapsed_time = 0
20
+
21
+ # self.current_progress = 0
22
+ self.count_saved = 0
23
+
24
+ self.cumulative_delta_time = 0
25
+ self.frame_list_txt = 0
26
+ self.cumulative_delta_time_raw = 0
27
+
28
+ self.cumulative_delta_time_list = []
29
+ self.cumulative_delta_time_list_raw = []
30
+
31
+ self.delta_timestart = datetime.now()
32
+ # self.delta_timestart_raw = datetime.now()
33
+ # self.delta_timestart = time.perf_counter()
34
+ # self.delta_timestart_raw = time.perf_counter()
35
+ self.start_time = datetime.now()
36
+ self.start_time_progress = datetime.now()
37
+
38
+ self.view.configurationlayout.acquisitionlayout.savinglayout.enable_record_checkbox.stateChanged.connect(self.inittime_save_slot)
39
+ self.view.configurationlayout.acquisitionlayout.savinglayout.apply_button.clicked.connect(self.init_time_save)
40
+ self.view.configurationlayout.acquisitionlayout.savinglayout.pauseresumebuttom.clicked.connect(self.pauseresumestate)
41
+
42
+ def mainloop(self):
43
+ if self.view.configurationlayout.acquisitionlayout.savinglayout.status_saving:
44
+ if self.stateresume:
45
+ _current_time = datetime.now()
46
+ self.elapsed_time = (_current_time - self.start_time).total_seconds()
47
+
48
+ interval = self.view.configurationlayout.acquisitionlayout.savinglayout.interval_saving.value()
49
+ progress_percent = min(int((self.elapsed_time / interval) * 100), 100)
50
+ self.view.configurationlayout.acquisitionlayout.savinglayout.progress.setValue(progress_percent)
51
+
52
+
53
+ if self.elapsed_time >= self.view.configurationlayout.acquisitionlayout.savinglayout.interval_saving.value():
54
+ self.intervalstart()
55
+ self.savingtxt()
56
+ self.start_time = _current_time
57
+ self.current_progress = 0
58
+ self.view.record_value_saved.setText(f"{self.count_saved}")
59
+ self.view.configurationlayout.acquisitionlayout.savinglayout.progress.setValue(0)
60
+ self.intervalend()
61
+ else:
62
+ _current_time = datetime.now()
63
+ self.start_time = _current_time - timedelta(seconds=self.elapsed_time)
64
+
65
+ self.delta_timestart = _current_time - timedelta(seconds=self.elapsed_time)
66
+ # self.delta_timestart_raw = _current_time - timedelta(seconds=self.elapsed_time)
67
+
68
+
69
+ def pauseresumestate(self):
70
+ if self.view.configurationlayout.acquisitionlayout.savinglayout.pauseresumebuttom.text() == "Pause":
71
+ self.stateresume = False
72
+ self.view.configurationlayout.acquisitionlayout.savinglayout.pauseresumebuttom.setText("Resume")
73
+
74
+ elif self.view.configurationlayout.acquisitionlayout.savinglayout.pauseresumebuttom.text() == "Resume":
75
+ self.stateresume = True
76
+ self.view.configurationlayout.acquisitionlayout.savinglayout.pauseresumebuttom.setText("Pause")
77
+
78
+ def intervalstart(self):
79
+ self.current_time = datetime.now()
80
+ self.current_time_raw = datetime.now()
81
+
82
+ def intervalend(self):
83
+ self.delta_timestart = self.delta_timeend
84
+ # self.delta_timestart_raw = self.delta_timeend_raw
85
+
86
+ def savingtxt(self):
87
+ processed_wavelengths, processed_intensities = self.model.acquire_spectrum()
88
+ raw_wavelengths, raw_intensities = self.model.acquire_spectrum_for_normalization()
89
+
90
+ self.delta_timeend = datetime.now()
91
+ self.delta_timeend_raw = datetime.now()
92
+ # self.delta_timeend = time.perf_counter()
93
+ # self.delta_timeend_raw = time.perf_counter()
94
+
95
+ self.delta_time = (self.delta_timeend - self.delta_timestart).total_seconds()
96
+ self.delta_time = np.array(self.delta_time)
97
+ self.delta_time = np.full(len(processed_intensities), self.delta_time)
98
+
99
+ self.frame_list_txt = self.frame_list_txt + 1
100
+
101
+ processed_data = [processed_wavelengths, processed_intensities, self.delta_time]
102
+ raw_data = [raw_wavelengths, raw_intensities, self.delta_time]
103
+
104
+ processed_data_transposed = list(map(list, zip(*processed_data)))
105
+ raw_data_transposed = list(map(list, zip(*raw_data)))
106
+
107
+ filename = self.current_time.strftime("%Y-%m-%d_%H-%M-%S")
108
+
109
+ self.mainpath = self.view.configurationlayout.acquisitionlayout.savinglayout.combined_path_text
110
+ os.makedirs(os.path.join(self.mainpath, 'processed'), exist_ok=True)
111
+ os.makedirs(os.path.join(self.mainpath, 'raw'), exist_ok=True)
112
+
113
+ save_path_processed = os.path.join(self.mainpath, 'processed', f'{self.frame_list_txt}-index-processed_spectrum_{filename}.txt')
114
+ save_path_raw = os.path.join(self.mainpath, 'raw', f'{self.frame_list_txt}-index-raw_spectrum_{filename}.txt')
115
+
116
+ for sublist in processed_data_transposed:
117
+ sublist.append(self.current_time.strftime("%Y-%m-%d %H-%M-%S-%f"))
118
+ try:
119
+ with open(save_path_processed, "w") as file:
120
+ file.write(("[wavelength, intensities, timedelta, date, time]") + "\n")
121
+ file.write((">>>>>Begin Processed Spectral Data<<<<<") + "\n")
122
+ for sublist in processed_data_transposed:
123
+ file.write(" ".join(map(str, sublist)) + "\n")
124
+ file.write((">>>>>End Processed Spectral Data<<<<<") + "\n")
125
+ self.count_saved = self.count_saved + 1
126
+ except:
127
+ print("error txt processed saved")
128
+ pass
129
+
130
+ for sublist in raw_data_transposed:
131
+ sublist.append(self.current_time.strftime("%Y-%m-%d %H-%M-%S-%f"))
132
+ try:
133
+ with open(save_path_raw, "w") as file:
134
+ file.write(("[wavelength, intensities, timedelta, date, time]") + "\n")
135
+ file.write((">>>>>Begin Processed Spectral Data<<<<<") + "\n")
136
+ for sublist in raw_data_transposed:
137
+ file.write(" ".join(map(str, sublist)) + "\n")
138
+ file.write((">>>>>End Processed Spectral Data<<<<<") + "\n")
139
+ self.count_saved = self.count_saved + 1
140
+ except:
141
+ print("error txt raw saved")
142
+ pass
143
+
144
+
145
+ def inittime_save_slot(self, state):
146
+ if state == 2:
147
+ self.view.configurationlayout.acquisitionlayout.savinglayout.inittime_save = datetime.now().strftime("%Y-%m-%d_%H-%M-%S_%f")
148
+ self.view.configurationlayout.acquisitionlayout.savinglayout.update_combined_text()
149
+ self.mainpath = self.view.configurationlayout.acquisitionlayout.savinglayout.combined_path_text
150
+
151
+ if state == 0:
152
+ self.count_saved = 0
153
+ self.view.record_value_saved.setText(f"{self.count_saved}")
154
+
155
+ def init_time_save(self):
156
+ if self.view.configurationlayout.acquisitionlayout.savinglayout.syncsensorgram.isChecked():
157
+ self.view.configurationlayout.plottinglayout.sensorgramlayout.reset_button.click()
158
+
159
+ self.processed_wavelengths = None
160
+ self.processed_intensities = None
161
+
162
+ self.raw_wavelengths = None
163
+ self.raw_intensities = None
164
+
165
+ # self.current_progress = 0
166
+ self.current_forprogress = 0
167
+ self.count_saved = 0
168
+
169
+
170
+ self.cumulative_delta_time = 0
171
+ self.frame_list_txt = 0
172
+ self.cumulative_delta_time_raw = 0
173
+
174
+ self.delta_timestart = datetime.now()
175
+ # self.delta_timestart = time.perf_counter()
176
+ self.cumulative_delta_time_list = []
177
+ # self.delta_timestart_raw = datetime.now()
178
+ # self.delta_timestart_raw = time.perf_counter()
179
+ self.cumulative_delta_time_list_raw = []
180
+ self.start_time = datetime.now()
181
+ self.start_time_progress = datetime.now()
182
+
183
+
184
+
185
+ def onesecond_left(self, start_time):
186
+ current_time = datetime.now()
187
+ elapsed_time = (current_time - start_time).total_seconds()
188
+ if elapsed_time >= 0.1:
189
+ return True
190
+ return False
@@ -0,0 +1,10 @@
1
+ from pyspectrace.Control.Configuration.Acquisition.Communication.communicationcontrol import CommunicationControl
2
+ from pyspectrace.Control.Configuration.Acquisition.Saving.savingcontrol import SavingControl
3
+ class AcquisitionControl:
4
+ def __init__(self,
5
+ model,
6
+ view):
7
+ self.model = model
8
+ self.view = view
9
+ self.communicationcontrol = CommunicationControl(model, view)
10
+ self.savingcontrol = SavingControl(model, view)
@@ -0,0 +1,6 @@
1
+ from PyQt5.QtCore import QTimer
2
+
3
+ class SpectrumControl:
4
+ def __init__(self, model, view):
5
+ self.model = model
6
+ self.view = view