pychemstation 0.10.3__tar.gz → 0.10.4__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.
- pychemstation-0.10.4/.pre-commit-config.yaml +10 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/PKG-INFO +2 -1
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/__init__.py +1 -1
- pychemstation-0.10.4/pychemstation/analysis/__init__.py +4 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/analysis/base_spectrum.py +7 -7
- {pychemstation-0.10.3/build/lib/pychemstation/utils → pychemstation-0.10.4/pychemstation/analysis}/chromatogram.py +4 -4
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/analysis/process_report.py +98 -61
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/__init__.py +3 -2
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/__init__.py +1 -5
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/comm.py +20 -11
- pychemstation-0.10.4/pychemstation/control/controllers/devices/device.py +49 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/controllers/devices/injector.py +20 -9
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/tables/method.py +233 -100
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/tables/ms.py +7 -4
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/controllers/tables/sequence.py +133 -53
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/controllers/tables/table.py +151 -91
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/hplc.py +86 -66
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/generated/__init__.py +0 -2
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/generated/pump_method.py +15 -19
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/macro.py +10 -9
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/method_types.py +1 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/utils/parsing.py +0 -11
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/sequence_types.py +2 -3
- {pychemstation-0.10.3/build/lib/pychemstation/analysis → pychemstation-0.10.4/pychemstation/utils}/spec_utils.py +1 -2
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/table_types.py +10 -9
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/tray_types.py +45 -36
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pyproject.toml +2 -1
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/tests/constants.py +67 -47
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/out.txt +1705 -0
- pychemstation-0.10.4/tests/test_method.py +63 -0
- pychemstation-0.10.3/tests/test_offline_stable.py → pychemstation-0.10.4/tests/test_offline_integration.py +27 -11
- pychemstation-0.10.3/tests/test_online_stable.py → pychemstation-0.10.4/tests/test_online_integration.py +80 -62
- pychemstation-0.10.3/build/lib/tests/test_runs_stable.py → pychemstation-0.10.4/tests/test_runs_integration.py +86 -65
- pychemstation-0.10.4/tests/test_sequence.py +22 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/uv.lock +131 -1
- pychemstation-0.10.3/build/lib/pychemstation/analysis/__init__.py +0 -5
- pychemstation-0.10.3/build/lib/pychemstation/analysis/process_report.py +0 -283
- pychemstation-0.10.3/build/lib/pychemstation/analysis/utils.py +0 -63
- pychemstation-0.10.3/build/lib/pychemstation/control/__init__.py +0 -8
- pychemstation-0.10.3/build/lib/pychemstation/control/comm.py +0 -206
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/devices/column.py +0 -12
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/devices/dad.py +0 -0
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/devices/device.py +0 -39
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/devices/injector.py +0 -51
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/devices/pump.py +0 -43
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/method.py +0 -338
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/sequence.py +0 -190
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/table_controller.py +0 -266
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/tables/sequence.py +0 -290
- pychemstation-0.10.3/build/lib/pychemstation/control/controllers/tables/table.py +0 -315
- pychemstation-0.10.3/build/lib/pychemstation/control/hplc.py +0 -299
- pychemstation-0.10.3/build/lib/pychemstation/control/table/__init__.py +0 -3
- pychemstation-0.10.3/build/lib/pychemstation/control/table/method.py +0 -274
- pychemstation-0.10.3/build/lib/pychemstation/control/table/sequence.py +0 -210
- pychemstation-0.10.3/build/lib/pychemstation/control/table/table_controller.py +0 -201
- pychemstation-0.10.3/build/lib/pychemstation/generated/pump_method.py +0 -519
- pychemstation-0.10.3/build/lib/pychemstation/utils/macro.py +0 -100
- pychemstation-0.10.3/build/lib/pychemstation/utils/method_types.py +0 -56
- pychemstation-0.10.3/build/lib/pychemstation/utils/num_utils.py +0 -65
- pychemstation-0.10.3/build/lib/pychemstation/utils/sequence_types.py +0 -54
- pychemstation-0.10.3/build/lib/pychemstation/utils/spec_utils.py +0 -304
- pychemstation-0.10.3/build/lib/pychemstation/utils/table_types.py +0 -95
- pychemstation-0.10.3/build/lib/pychemstation/utils/tray_types.py +0 -183
- pychemstation-0.10.3/build/lib/tests/test_comb.py +0 -136
- pychemstation-0.10.3/build/lib/tests/test_comm.py +0 -65
- pychemstation-0.10.3/build/lib/tests/test_inj.py +0 -39
- pychemstation-0.10.3/build/lib/tests/test_method.py +0 -99
- pychemstation-0.10.3/build/lib/tests/test_nightly.py +0 -80
- pychemstation-0.10.3/build/lib/tests/test_offline_stable.py +0 -69
- pychemstation-0.10.3/build/lib/tests/test_online_stable.py +0 -275
- pychemstation-0.10.3/build/lib/tests/test_proc_rep.py +0 -52
- pychemstation-0.10.3/build/lib/tests/test_sequence.py +0 -125
- pychemstation-0.10.3/build/lib/tests/test_stable.py +0 -276
- pychemstation-0.10.3/pychemstation/__init__.py +0 -3
- pychemstation-0.10.3/pychemstation/analysis/__init__.py +0 -9
- pychemstation-0.10.3/pychemstation/analysis/base_spectrum.py +0 -506
- pychemstation-0.10.3/pychemstation/control/controllers/__init__.py +0 -13
- pychemstation-0.10.3/pychemstation/control/controllers/comm.py +0 -222
- pychemstation-0.10.3/pychemstation/control/controllers/devices/__init__.py +0 -0
- pychemstation-0.10.3/pychemstation/control/controllers/devices/device.py +0 -39
- pychemstation-0.10.3/pychemstation/control/controllers/tables/__init__.py +0 -0
- pychemstation-0.10.3/pychemstation/control/controllers/tables/method.py +0 -405
- pychemstation-0.10.3/pychemstation/control/controllers/tables/ms.py +0 -21
- pychemstation-0.10.3/pychemstation/generated/__init__.py +0 -56
- pychemstation-0.10.3/pychemstation/generated/dad_method.py +0 -367
- pychemstation-0.10.3/pychemstation/utils/__init__.py +0 -0
- pychemstation-0.10.3/pychemstation/utils/chromatogram.py +0 -116
- pychemstation-0.10.3/pychemstation/utils/injector_types.py +0 -52
- pychemstation-0.10.3/pychemstation/utils/parsing.py +0 -291
- pychemstation-0.10.3/pychemstation/utils/pump_types.py +0 -7
- pychemstation-0.10.3/pychemstation/utils/spec_utils.py +0 -304
- pychemstation-0.10.3/tests/__init__.py +0 -0
- pychemstation-0.10.3/tests/constants.py +0 -134
- pychemstation-0.10.3/tests/test_runs_stable.py +0 -225
- {pychemstation-0.10.3 → pychemstation-0.10.4}/.gitignore +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/.gitlab-ci.yml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/CHANGELOG.md +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/CONTRIBUTING.md +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/LICENSE +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/README.md +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/index.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/analysis/base_spectrum.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/analysis/spec_utils.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/analysis/utils.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/analysis.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/control/chromatogram.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/control/hplc.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/control.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/generated.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/utils/chemstation.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/utils/constants.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/utils/hplc_param_types.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation/utils.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/pychemstation.html +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/doc/search.js +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/README.md +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/controllers/README.md +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/devices/__init__.py +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/tables/__init__.py +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/generated/dad_method.py +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/utils/__init__.py +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/utils/injector_types.py +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/utils/num_utils.py +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/utils/pump_types.py +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation.egg-info/PKG-INFO +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation.egg-info/SOURCES.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation.egg-info/dependency_links.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation.egg-info/requires.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation.egg-info/top_level.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/0_2025-03-15 19-14-35.PDF +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/ACQRES.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/CSlbk.ini +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DA.M/DAMETHOD.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DA.M/INFO.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DA.M/RECALIB.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DA.M/rpthead.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1.UV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1A.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1A.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1B.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1B.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1C.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1C.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1D.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1D.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1E.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DAD1E.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/DiagResults.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/PMP1.AnalyticalResults.drvml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/REPORT01.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/REPORT02.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/REPORT03.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/REPORT04.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/REPORT05.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/RUN.LOG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/Report.TXT +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/Report00.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/Report01.xls +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/SAMPLE.XML +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/SAMPLE.XML.bak +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/WLS1.Sampler.scml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/acq.macaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/acq.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/acq_MethHist.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/acq_damethod.reg +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/da.macaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/lcdiag.reg +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/sample.acaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/0_2025-03-15 19-14-35.D/single.B +0 -0
- {pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/tests/__init__.py +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_talk.mac +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/CSlbk.ini +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/ACQ.MS +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/Agilent1200erDadDriver1.RapidControl.ConfigXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/Agilent1200erDadDriver1.RapidControl.MethodMetaData.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/Agilent1200erDadDriver1.RapidControl.MethodXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentColumnCompDriver1.RapidControl.ConfigXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentColumnCompDriver1.RapidControl.MethodMetaData.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentColumnCompDriver1.RapidControl.MethodXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentPumpDriver1.RapidControl.ConfigXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentPumpDriver1.RapidControl.MethodMetaData.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentPumpDriver1.RapidControl.MethodXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentSamplerDriver1.RapidControl.ConfigXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentSamplerDriver1.RapidControl.MethodMetaData.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentSamplerDriver1.RapidControl.MethodXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/AgilentSamplerDriver1.RapidControl.PretreatXML.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/DAMETHOD.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/FIA.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/INFO.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/INJECTOR.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/MassHunterIntegration.ini +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/RECALIB.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/RapidControl.InstrumentConfig.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/rpthead.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/GENERAL-POROSHELL-OPT.M/smpl_pur.mth +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/Methods.Reg +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/hplc_testing.B +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/hplc_testing.LOG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/hplc_testing.S +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/hplc_testing.Start +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/ACQRES.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/CSlbk.ini +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DA.M/DAMETHOD.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DA.M/INFO.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DA.M/RECALIB.MTH +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DA.M/rpthead.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1.UV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1A.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1A.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1B.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1B.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1C.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1C.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1D.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1D.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1E.ch +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DAD1E.npz +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/DiagResults.REG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/Limsinf.xml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/PMP1.AnalyticalResults.drvml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/REPORT01.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/REPORT02.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/REPORT03.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/REPORT04.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/REPORT05.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/RUN.LOG +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/Report.TXT +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/Report00.CSV +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/Report01.xls +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/SAMPLE.XML +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/SAMPLE.XML.bak +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/WLS1.Sampler.scml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/acq.macaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/acq.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/acq_MethHist.txt +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/acq_damethod.reg +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/da.macaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/hplc_testing 2025-03-27 17-13-47_run seq with new method.PDF +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/lcdiag.reg +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/run seq with new method.D/sequence.acam_ +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/tests/hplc_testing 2025-03-27 17-13-47/sequence.acaml +0 -0
- {pychemstation-0.10.3 → pychemstation-0.10.4}/update-lib.sh +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: pychemstation
|
3
|
-
Version: 0.10.
|
3
|
+
Version: 0.10.4
|
4
4
|
Summary: Library to interact with Chemstation software, primarily used in Hein lab
|
5
5
|
Project-URL: Documentation, https://pychemstation-e5a086.gitlab.io/pychemstation.html
|
6
6
|
Project-URL: Repository, https://gitlab.com/heingroup/device-api/pychemstation
|
@@ -18,6 +18,7 @@ Requires-Dist: matplotlib>=3.7.5
|
|
18
18
|
Requires-Dist: pandas>=2.0.3
|
19
19
|
Requires-Dist: pdoc>=14.7.0
|
20
20
|
Requires-Dist: polling>=0.3.2
|
21
|
+
Requires-Dist: pre-commit>=4.2.0
|
21
22
|
Requires-Dist: pytest>=7.3.5
|
22
23
|
Requires-Dist: rainbow-api>=1.0.10
|
23
24
|
Requires-Dist: result>=0.17.0
|
{pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/analysis/base_spectrum.py
RENAMED
@@ -197,10 +197,10 @@ class AbstractSpectrum(ABC):
|
|
197
197
|
return (self.x.copy()[full_mask], self.y.copy()[full_mask])
|
198
198
|
|
199
199
|
def show_spectrum(
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
200
|
+
self,
|
201
|
+
filename=None,
|
202
|
+
title=None,
|
203
|
+
label=None,
|
204
204
|
):
|
205
205
|
"""Plots the spectral data using matplotlib.pyplot module.
|
206
206
|
|
@@ -249,7 +249,7 @@ class AbstractSpectrum(ABC):
|
|
249
249
|
os.makedirs(path, exist_ok=True)
|
250
250
|
fig.savefig(os.path.join(path, f"{filename}.png"), dpi=150)
|
251
251
|
|
252
|
-
def find_peaks(self, threshold=1, min_width
|
252
|
+
def find_peaks(self, threshold=1, min_width=0.1, min_dist=None, area=None):
|
253
253
|
"""Finds all peaks above the threshold with at least min_width width.
|
254
254
|
|
255
255
|
Args:
|
@@ -385,12 +385,12 @@ class AbstractSpectrum(ABC):
|
|
385
385
|
|
386
386
|
if rule == "trapz":
|
387
387
|
return integrate.trapz(
|
388
|
-
self.y[left_idx: right_idx + 1], self.x[left_idx: right_idx + 1]
|
388
|
+
self.y[left_idx : right_idx + 1], self.x[left_idx : right_idx + 1]
|
389
389
|
)
|
390
390
|
|
391
391
|
elif rule == "simps":
|
392
392
|
return integrate.simps(
|
393
|
-
self.y[left_idx: right_idx + 1], self.x[left_idx: right_idx + 1]
|
393
|
+
self.y[left_idx : right_idx + 1], self.x[left_idx : right_idx + 1]
|
394
394
|
)
|
395
395
|
|
396
396
|
else:
|
@@ -6,8 +6,9 @@ from dataclasses import dataclass
|
|
6
6
|
|
7
7
|
import numpy as np
|
8
8
|
|
9
|
-
|
10
|
-
from .parsing import CHFile
|
9
|
+
|
10
|
+
from ..utils.parsing import CHFile
|
11
|
+
from ..analysis.base_spectrum import AbstractSpectrum
|
11
12
|
|
12
13
|
ACQUISITION_PARAMETERS = "acq.txt"
|
13
14
|
|
@@ -36,12 +37,11 @@ class AgilentHPLCChromatogram(AbstractSpectrum):
|
|
36
37
|
}
|
37
38
|
|
38
39
|
def __init__(self, path=None, autosaving=False):
|
39
|
-
|
40
40
|
if path is not None:
|
41
41
|
os.makedirs(path, exist_ok=True)
|
42
42
|
self.path = path
|
43
43
|
else:
|
44
|
-
self.path = os.path.join("
|
44
|
+
self.path = os.path.join("../utils", "hplc_data")
|
45
45
|
os.makedirs(self.path, exist_ok=True)
|
46
46
|
|
47
47
|
super().__init__(path=path, autosaving=autosaving)
|
@@ -17,8 +17,8 @@ from aghplctools.ingestion.text import (
|
|
17
17
|
)
|
18
18
|
from result import Err, Ok, Result
|
19
19
|
|
20
|
-
from
|
21
|
-
from
|
20
|
+
from ..analysis.chromatogram import AgilentHPLCChromatogram
|
21
|
+
from ..utils.tray_types import FiftyFourVialPlate, Tray
|
22
22
|
|
23
23
|
|
24
24
|
@dataclass
|
@@ -76,9 +76,11 @@ class CSVProcessor(ReportProcessor):
|
|
76
76
|
:return: subset of complete report details, specifically the sample location, solvents in pumps,
|
77
77
|
and list of peaks at each wavelength channel.
|
78
78
|
"""
|
79
|
-
labels = os.path.join(self.path,
|
79
|
+
labels = os.path.join(self.path, "REPORT00.CSV")
|
80
80
|
if os.path.exists(labels):
|
81
|
-
df_labels: Dict[int, Dict[int:
|
81
|
+
df_labels: Dict[int, Dict[int:AnyStr]] = pd.read_csv(
|
82
|
+
labels, encoding="utf-16", header=None
|
83
|
+
).to_dict()
|
82
84
|
vial_location = []
|
83
85
|
signals = {}
|
84
86
|
solvents = {}
|
@@ -91,18 +93,28 @@ class CSVProcessor(ReportProcessor):
|
|
91
93
|
elif val == "Number of Signals":
|
92
94
|
num_signals = int(df_labels[1][pos])
|
93
95
|
for s in range(1, num_signals + 1):
|
94
|
-
df = pd.read_csv(
|
95
|
-
|
96
|
+
df = pd.read_csv(
|
97
|
+
os.path.join(self.path, f"REPORT0{s}.CSV"),
|
98
|
+
encoding="utf-16",
|
99
|
+
header=None,
|
100
|
+
)
|
96
101
|
peaks = df.apply(lambda row: AgilentPeak(*row), axis=1)
|
97
|
-
wavelength = df_labels[1][pos + s].partition(",4 Ref=off")[0][
|
102
|
+
wavelength = df_labels[1][pos + s].partition(",4 Ref=off")[0][
|
103
|
+
-3:
|
104
|
+
]
|
98
105
|
signals[wavelength] = list(peaks)
|
99
106
|
break
|
100
107
|
|
101
|
-
return Ok(
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
108
|
+
return Ok(
|
109
|
+
AgilentReport(
|
110
|
+
signals=[
|
111
|
+
Signals(wavelength=int(w), peaks=s, data=None)
|
112
|
+
for w, s in signals.items()
|
113
|
+
],
|
114
|
+
vial_location=FiftyFourVialPlate.from_int(int(vial_location)),
|
115
|
+
solvents=solvents,
|
116
|
+
)
|
117
|
+
)
|
106
118
|
|
107
119
|
return Err("No report found")
|
108
120
|
|
@@ -111,34 +123,39 @@ class TXTProcessor(ReportProcessor):
|
|
111
123
|
"""
|
112
124
|
Regex matches for column and unit combinations, courtesy of Veronica Lai.
|
113
125
|
"""
|
126
|
+
|
114
127
|
_column_re_dictionary = {
|
115
|
-
|
116
|
-
|
128
|
+
"Peak": { # peak index
|
129
|
+
"#": "[ ]+(?P<Peak>[\d]+)", # number
|
117
130
|
},
|
118
|
-
|
119
|
-
|
131
|
+
"RetTime": { # retention time
|
132
|
+
"[min]": "(?P<RetTime>[\d]+.[\d]+)", # minutes
|
120
133
|
},
|
121
|
-
|
122
|
-
|
134
|
+
"Type": { # peak type
|
135
|
+
"": "(?P<Type>[A-Z]{1,3}(?: [A-Z]{1,2})*)", # todo this is different from <4.8.8 aghplc tools
|
123
136
|
},
|
124
|
-
|
125
|
-
|
137
|
+
"Width": { # peak width
|
138
|
+
"[min]": "(?P<Width>[\d]+.[\d]+[e+-]*[\d]+)",
|
126
139
|
},
|
127
|
-
|
128
|
-
|
129
|
-
|
140
|
+
"Area": { # peak area
|
141
|
+
"[mAU*s]": "(?P<Area>[\d]+.[\d]+[e+-]*[\d]+)", # area units
|
142
|
+
"%": "(?P<percent>[\d]+.[\d]+[e+-]*[\d]+)", # percent
|
130
143
|
},
|
131
|
-
|
132
|
-
|
144
|
+
"Height": { # peak height
|
145
|
+
"[mAU]": "(?P<Height>[\d]+.[\d]+[e+-]*[\d]+)",
|
133
146
|
},
|
134
|
-
|
135
|
-
|
147
|
+
"Name": {
|
148
|
+
"": "(?P<Name>[^\s]+(?:\s[^\s]+)*)", # peak name
|
136
149
|
},
|
137
150
|
}
|
138
151
|
|
139
|
-
def __init__(
|
140
|
-
|
141
|
-
|
152
|
+
def __init__(
|
153
|
+
self,
|
154
|
+
path: str,
|
155
|
+
min_ret_time: int = 0,
|
156
|
+
max_ret_time: int = 999,
|
157
|
+
target_wavelength_range: List[int] = range(200, 300),
|
158
|
+
):
|
142
159
|
"""
|
143
160
|
Class to process reports in CSV form.
|
144
161
|
|
@@ -163,7 +180,9 @@ class TXTProcessor(ReportProcessor):
|
|
163
180
|
and list of peaks at each wavelength channel.
|
164
181
|
"""
|
165
182
|
|
166
|
-
with open(
|
183
|
+
with open(
|
184
|
+
os.path.join(self.path, "REPORT.TXT"), "r", encoding="utf-16"
|
185
|
+
) as openfile:
|
167
186
|
text = openfile.read()
|
168
187
|
|
169
188
|
try:
|
@@ -171,25 +190,33 @@ class TXTProcessor(ReportProcessor):
|
|
171
190
|
except ValueError as e:
|
172
191
|
return Err("No peaks found: " + str(e))
|
173
192
|
|
174
|
-
signals = {
|
193
|
+
signals = {
|
194
|
+
key: signals[key] for key in self.target_wavelength_range if key in signals
|
195
|
+
}
|
175
196
|
|
176
197
|
parsed_signals = []
|
177
198
|
for wavelength, wavelength_dict in signals.items():
|
178
|
-
current_wavelength_signals = Signals(
|
199
|
+
current_wavelength_signals = Signals(
|
200
|
+
wavelength=int(wavelength), peaks=[], data=None
|
201
|
+
)
|
179
202
|
for ret_time, ret_time_dict in wavelength_dict.items():
|
180
203
|
if self.min_ret_time <= ret_time <= self.max_ret_time:
|
181
|
-
current_wavelength_signals.peaks.append(
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
204
|
+
current_wavelength_signals.peaks.append(
|
205
|
+
AgilentPeak(
|
206
|
+
retention_time=ret_time,
|
207
|
+
area=ret_time_dict["Area"],
|
208
|
+
width=ret_time_dict["Width"],
|
209
|
+
height=ret_time_dict["Height"],
|
210
|
+
peak_number=None,
|
211
|
+
peak_type=ret_time_dict["Type"],
|
212
|
+
area_percent=None,
|
213
|
+
)
|
214
|
+
)
|
188
215
|
parsed_signals.append(current_wavelength_signals)
|
189
216
|
|
190
|
-
return Ok(
|
191
|
-
|
192
|
-
|
217
|
+
return Ok(
|
218
|
+
AgilentReport(vial_location=None, solvents=None, signals=parsed_signals)
|
219
|
+
)
|
193
220
|
|
194
221
|
def parse_area_report(self, report_text: str) -> Dict:
|
195
222
|
"""
|
@@ -205,7 +232,7 @@ class TXTProcessor(ReportProcessor):
|
|
205
232
|
should be able to use the `parse_area_report` method of aghplctools v4.8.8
|
206
233
|
"""
|
207
234
|
if re.search(_no_peaks_re, report_text): # There are no peaks in Report.txt
|
208
|
-
raise ValueError(
|
235
|
+
raise ValueError("No peaks found in Report.txt")
|
209
236
|
blocks = _header_block_re.split(report_text)
|
210
237
|
signals = {} # output dictionary
|
211
238
|
for ind, block in enumerate(blocks):
|
@@ -218,23 +245,28 @@ class TXTProcessor(ReportProcessor):
|
|
218
245
|
si = _signal_info_re.match(table)
|
219
246
|
if si is not None:
|
220
247
|
# some error state (e.g. 'not found')
|
221
|
-
if si.group(
|
248
|
+
if si.group("error") != "":
|
222
249
|
continue
|
223
|
-
wavelength = float(si.group(
|
250
|
+
wavelength = float(si.group("wavelength"))
|
224
251
|
if wavelength in signals:
|
225
252
|
# placeholder error raise just in case (this probably won't happen)
|
226
253
|
raise KeyError(
|
227
|
-
f
|
254
|
+
f"The wavelength {float(si.group('wavelength'))} is already in the signals dictionary"
|
255
|
+
)
|
228
256
|
signals[wavelength] = {}
|
229
257
|
# build peak regex
|
230
258
|
peak_re = self.build_peak_regex(table)
|
231
|
-
if
|
259
|
+
if (
|
260
|
+
peak_re is None
|
261
|
+
): # if there are no columns (empty table), continue
|
232
262
|
continue
|
233
|
-
for line in table.split(
|
263
|
+
for line in table.split("\n"):
|
234
264
|
peak = peak_re.match(line)
|
235
265
|
if peak is not None:
|
236
|
-
signals[wavelength][float(peak.group(
|
237
|
-
current = signals[wavelength][
|
266
|
+
signals[wavelength][float(peak.group("RetTime"))] = {}
|
267
|
+
current = signals[wavelength][
|
268
|
+
float(peak.group("RetTime"))
|
269
|
+
]
|
238
270
|
for key in self._column_re_dictionary:
|
239
271
|
if key in peak.re.groupindex:
|
240
272
|
try: # try float conversion, otherwise continue
|
@@ -253,30 +285,35 @@ class TXTProcessor(ReportProcessor):
|
|
253
285
|
:param signal_table: block of lines associated with an area table
|
254
286
|
:return: peak line regex object (<=3.6 _sre.SRE_PATTERN, >=3.7 re.Pattern)
|
255
287
|
"""
|
256
|
-
split_table = signal_table.split(
|
288
|
+
split_table = signal_table.split("\n")
|
257
289
|
if len(split_table) <= 4: # catch peak table with no values
|
258
290
|
return None
|
259
291
|
# todo verify that these indicies are always true
|
260
292
|
column_line = split_table[2] # table column line
|
261
293
|
unit_line = split_table[3] # column unit line
|
262
|
-
length_line = [len(val) + 1 for val in split_table[4].split(
|
294
|
+
length_line = [len(val) + 1 for val in split_table[4].split("|")] # length line
|
263
295
|
|
264
296
|
# iterate over header values and units to build peak table regex
|
265
297
|
peak_re_string = []
|
266
298
|
for header, unit in zip(
|
267
|
-
|
268
|
-
chunk_string(unit_line, length_line)
|
299
|
+
chunk_string(column_line, length_line), chunk_string(unit_line, length_line)
|
269
300
|
):
|
270
|
-
if header ==
|
301
|
+
if header == "": # todo create a better catch for an undefined header
|
271
302
|
continue
|
272
303
|
try:
|
273
304
|
peak_re_string.append(
|
274
|
-
self._column_re_dictionary[header][
|
305
|
+
self._column_re_dictionary[header][
|
306
|
+
unit
|
307
|
+
] # append the appropriate regex
|
275
308
|
)
|
276
309
|
except KeyError: # catch for undefined regexes (need to be built)
|
277
|
-
raise KeyError(
|
278
|
-
|
310
|
+
raise KeyError(
|
311
|
+
f'The header/unit combination "{header}" "{unit}" is not defined in the peak regex '
|
312
|
+
f"dictionary. Let Lars know."
|
313
|
+
)
|
279
314
|
return re.compile(
|
280
|
-
|
281
|
-
|
315
|
+
"[ ]+".join(
|
316
|
+
peak_re_string
|
317
|
+
) # constructed string delimited by 1 or more spaces
|
318
|
+
+ "[\s]*" # and any remaining white space
|
282
319
|
)
|
@@ -6,8 +6,4 @@ from .comm import CommunicationController
|
|
6
6
|
from .tables.method import MethodController
|
7
7
|
from .tables.sequence import SequenceController
|
8
8
|
|
9
|
-
__all__ = [
|
10
|
-
'CommunicationController',
|
11
|
-
'MethodController',
|
12
|
-
'SequenceController'
|
13
|
-
]
|
9
|
+
__all__ = ["CommunicationController", "MethodController", "SequenceController"]
|
{pychemstation-0.10.3/build/lib → pychemstation-0.10.4}/pychemstation/control/controllers/comm.py
RENAMED
@@ -9,6 +9,7 @@ been processed.
|
|
9
9
|
|
10
10
|
Authors: Alexander Hammer, Hessam Mehr, Lucy Hao
|
11
11
|
"""
|
12
|
+
|
12
13
|
import os
|
13
14
|
import time
|
14
15
|
from typing import Optional, Union
|
@@ -34,11 +35,11 @@ class CommunicationController:
|
|
34
35
|
MAX_CMD_NO = 255
|
35
36
|
|
36
37
|
def __init__(
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
38
|
+
self,
|
39
|
+
comm_dir: str,
|
40
|
+
cmd_file: str = "cmd",
|
41
|
+
reply_file: str = "reply",
|
42
|
+
debug: bool = False,
|
42
43
|
):
|
43
44
|
"""
|
44
45
|
:param comm_dir:
|
@@ -62,7 +63,7 @@ class CommunicationController:
|
|
62
63
|
self.reset_cmd_counter()
|
63
64
|
|
64
65
|
# Initialize row counter for table operations
|
65
|
-
self.send(
|
66
|
+
self.send("Local Rows")
|
66
67
|
|
67
68
|
def get_num_val(self, cmd: str) -> Union[int, float]:
|
68
69
|
tries = 5
|
@@ -194,7 +195,7 @@ class CommunicationController:
|
|
194
195
|
def receive(self) -> Result[Response, str]:
|
195
196
|
"""Returns messages received in reply file.
|
196
197
|
|
197
|
-
:return: ChemStation response
|
198
|
+
:return: ChemStation response
|
198
199
|
"""
|
199
200
|
num_response_prefix = "Numerical Responses:"
|
200
201
|
str_response_prefix = "String Responses:"
|
@@ -203,10 +204,18 @@ class CommunicationController:
|
|
203
204
|
lines = possible_response.ok_value.splitlines()
|
204
205
|
for line in lines:
|
205
206
|
if str_response_prefix in line and num_response_prefix in line:
|
206
|
-
string_responses_dirty, _, numerical_responses = line.partition(
|
207
|
-
|
208
|
-
|
209
|
-
|
207
|
+
string_responses_dirty, _, numerical_responses = line.partition(
|
208
|
+
num_response_prefix
|
209
|
+
)
|
210
|
+
_, _, string_responses = string_responses_dirty.partition(
|
211
|
+
str_response_prefix
|
212
|
+
)
|
213
|
+
return Ok(
|
214
|
+
Response(
|
215
|
+
string_response=string_responses.strip(),
|
216
|
+
num_response=float(numerical_responses.strip()),
|
217
|
+
)
|
218
|
+
)
|
210
219
|
return Err("Could not retrieve HPLC response")
|
211
220
|
else:
|
212
221
|
return Err(f"Could not establish response to HPLC: {possible_response}")
|
@@ -0,0 +1,49 @@
|
|
1
|
+
import abc
|
2
|
+
from typing import List, Union, Dict, Optional
|
3
|
+
|
4
|
+
from result import Result
|
5
|
+
|
6
|
+
from ....analysis.process_report import AgilentReport, ReportType
|
7
|
+
from ....control.controllers import CommunicationController
|
8
|
+
from ....control.controllers.tables.table import TableController
|
9
|
+
from pychemstation.analysis.chromatogram import (
|
10
|
+
AgilentChannelChromatogramData,
|
11
|
+
AgilentHPLCChromatogram,
|
12
|
+
)
|
13
|
+
from ....utils.table_types import T, Table
|
14
|
+
|
15
|
+
|
16
|
+
class DeviceController(TableController, abc.ABC):
|
17
|
+
def __init__(
|
18
|
+
self, controller: CommunicationController, table: Table, offline: bool
|
19
|
+
):
|
20
|
+
super().__init__(
|
21
|
+
controller=controller, src=None, data_dirs=[], table=table, offline=offline
|
22
|
+
)
|
23
|
+
|
24
|
+
@abc.abstractmethod
|
25
|
+
def get_row(self, row: int):
|
26
|
+
pass
|
27
|
+
|
28
|
+
def retrieve_recent_data_files(self):
|
29
|
+
raise NotImplementedError
|
30
|
+
|
31
|
+
def fuzzy_match_most_recent_folder(self, most_recent_folder: T) -> Result[T, str]:
|
32
|
+
raise NotImplementedError
|
33
|
+
|
34
|
+
def get_report(
|
35
|
+
self, report_type: ReportType = ReportType.TXT
|
36
|
+
) -> List[AgilentReport]:
|
37
|
+
raise NotImplementedError
|
38
|
+
|
39
|
+
def get_data_uv(
|
40
|
+
self,
|
41
|
+
) -> Union[
|
42
|
+
List[Dict[str, AgilentHPLCChromatogram]], Dict[str, AgilentHPLCChromatogram]
|
43
|
+
]:
|
44
|
+
raise NotImplementedError
|
45
|
+
|
46
|
+
def get_data(
|
47
|
+
self, custom_path: Optional[str] = None
|
48
|
+
) -> Union[List[AgilentChannelChromatogramData], AgilentChannelChromatogramData]:
|
49
|
+
raise NotImplementedError
|
{pychemstation-0.10.3 → pychemstation-0.10.4}/pychemstation/control/controllers/devices/injector.py
RENAMED
@@ -1,4 +1,3 @@
|
|
1
|
-
|
2
1
|
from ....control.controllers import CommunicationController
|
3
2
|
from ....utils.injector_types import (
|
4
3
|
Draw,
|
@@ -17,8 +16,9 @@ from .device import DeviceController
|
|
17
16
|
|
18
17
|
|
19
18
|
class InjectorController(DeviceController):
|
20
|
-
|
21
|
-
|
19
|
+
def __init__(
|
20
|
+
self, controller: CommunicationController, table: Table, offline: bool
|
21
|
+
):
|
22
22
|
super().__init__(controller, table, offline)
|
23
23
|
|
24
24
|
def get_row(self, row: int) -> InjectorFunction:
|
@@ -34,17 +34,28 @@ class InjectorController(DeviceController):
|
|
34
34
|
# TODO: better error handling
|
35
35
|
is_source = SourceType(self.get_text(row, RegisterFlag.DRAW_SOURCE))
|
36
36
|
is_volume = Mode(self.get_text(row, RegisterFlag.DRAW_VOLUME))
|
37
|
-
vol =
|
37
|
+
vol = (
|
38
|
+
self.get_num(row, RegisterFlag.DRAW_VOLUME_VALUE)
|
39
|
+
if is_volume == Mode.SET
|
40
|
+
else None
|
41
|
+
)
|
38
42
|
if is_source is SourceType.SPECIFIC_LOCATION:
|
39
43
|
return Draw(amount=vol, source=return_tray_loc())
|
40
44
|
elif is_source is SourceType.LOCATION:
|
41
|
-
return Draw(
|
45
|
+
return Draw(
|
46
|
+
amount=vol, location=self.get_text(row, RegisterFlag.DRAW_LOCATION)
|
47
|
+
)
|
42
48
|
elif function == "Remote":
|
43
|
-
return Remote(
|
44
|
-
|
49
|
+
return Remote(
|
50
|
+
command=RemoteCommand(self.get_text(row, RegisterFlag.REMOTE)),
|
51
|
+
duration=self.get_num(row, RegisterFlag.REMOTE_DUR),
|
52
|
+
)
|
45
53
|
|
46
54
|
def load(self) -> InjectorTable:
|
47
55
|
rows = self.get_num_rows()
|
48
56
|
if rows.is_ok():
|
49
|
-
return InjectorTable(
|
50
|
-
|
57
|
+
return InjectorTable(
|
58
|
+
functions=[
|
59
|
+
self.get_row(i) for i in range(int(rows.ok_value.num_response))
|
60
|
+
]
|
61
|
+
)
|