dasexplorer 1.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.
- dasexplorer-1.0.0/CITATION.cff +40 -0
- dasexplorer-1.0.0/LICENSE +23 -0
- dasexplorer-1.0.0/MANIFEST.in +7 -0
- dasexplorer-1.0.0/PKG-INFO +125 -0
- dasexplorer-1.0.0/README.md +64 -0
- dasexplorer-1.0.0/dasexplorer/__init__.py +2 -0
- dasexplorer-1.0.0/dasexplorer/__main__.py +60 -0
- dasexplorer-1.0.0/dasexplorer/about.txt +8 -0
- dasexplorer-1.0.0/dasexplorer/cfg/config.json +82 -0
- dasexplorer-1.0.0/dasexplorer/core/__init__.py +0 -0
- dasexplorer-1.0.0/dasexplorer/core/analysis.py +89 -0
- dasexplorer-1.0.0/dasexplorer/core/annotation_export.py +302 -0
- dasexplorer-1.0.0/dasexplorer/core/annotations.py +364 -0
- dasexplorer-1.0.0/dasexplorer/core/config.py +188 -0
- dasexplorer-1.0.0/dasexplorer/core/data_model.py +67 -0
- dasexplorer-1.0.0/dasexplorer/core/readers.py +485 -0
- dasexplorer-1.0.0/dasexplorer/core/rgb.py +80 -0
- dasexplorer-1.0.0/dasexplorer/gui/__init__.py +0 -0
- dasexplorer-1.0.0/dasexplorer/gui/analysis_dialogs.py +1853 -0
- dasexplorer-1.0.0/dasexplorer/gui/annotation_widget.py +299 -0
- dasexplorer-1.0.0/dasexplorer/gui/batch_annotations_dialog.py +282 -0
- dasexplorer-1.0.0/dasexplorer/gui/batch_conversion_dialog.py +747 -0
- dasexplorer-1.0.0/dasexplorer/gui/batch_data_dialog.py +275 -0
- dasexplorer-1.0.0/dasexplorer/gui/config_profile_dialog.py +437 -0
- dasexplorer-1.0.0/dasexplorer/gui/main_window.py +2463 -0
- dasexplorer-1.0.0/dasexplorer/gui/tab_bar.py +47 -0
- dasexplorer-1.0.0/dasexplorer/gui/theme.py +250 -0
- dasexplorer-1.0.0/dasexplorer/gui/waterfall.py +1891 -0
- dasexplorer-1.0.0/dasexplorer/icons/icon_1.ico +0 -0
- dasexplorer-1.0.0/dasexplorer/icons/icon_2.ico +0 -0
- dasexplorer-1.0.0/dasexplorer/icons/screenshot.png +0 -0
- dasexplorer-1.0.0/dasexplorer/tools/apl/__init__.py +0 -0
- dasexplorer-1.0.0/dasexplorer/tools/apl/io.py +0 -0
- dasexplorer-1.0.0/dasexplorer/tools/apl/utils_2_5.py +31 -0
- dasexplorer-1.0.0/dasexplorer/tools/apl/utils_3_5.py +9 -0
- dasexplorer-1.0.0/dasexplorer/version.py +5 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/PKG-INFO +125 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/SOURCES.txt +43 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/dependency_links.txt +1 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/entry_points.txt +2 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/requires.txt +14 -0
- dasexplorer-1.0.0/dasexplorer.egg-info/top_level.txt +1 -0
- dasexplorer-1.0.0/pyproject.toml +59 -0
- dasexplorer-1.0.0/setup.cfg +4 -0
- dasexplorer-1.0.0/setup.py +3 -0
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: "If you use DASexplorer in your research, please cite it as below."
|
|
3
|
+
type: software
|
|
4
|
+
title: "DASexplorer"
|
|
5
|
+
abstract: >
|
|
6
|
+
DASexplorer is an open-source desktop application for visualisation,
|
|
7
|
+
analysis and annotation of Distributed Acoustic Sensing (DAS) data.
|
|
8
|
+
It supports multiple interrogator formats, profile-based configuration,
|
|
9
|
+
multispectral RGB representation, F-K filtering, and annotations conversion
|
|
10
|
+
to YOLO, COCO and Raven Pro formats.
|
|
11
|
+
authors:
|
|
12
|
+
- family-names: Morell-Monzó
|
|
13
|
+
given-names: Sergio
|
|
14
|
+
orcid: "https://orcid.org/0000-0001-8883-2618"
|
|
15
|
+
affiliation: "Institut d'Investigació per a la Gestío Integrada de Zones Costaneres (IGIC-UPV), Universitat Politècnica de València"
|
|
16
|
+
email: sermomon@upv.es
|
|
17
|
+
version: "1.0.0"
|
|
18
|
+
date-released: "2026-06-25"
|
|
19
|
+
license: MIT
|
|
20
|
+
repository-code: "https://github.com/sermomon/DASexplorer"
|
|
21
|
+
doi: "10.5281/zenodo.21032550"
|
|
22
|
+
keywords:
|
|
23
|
+
- distributed acoustic sensing
|
|
24
|
+
- DAS
|
|
25
|
+
- fiber optic sensing
|
|
26
|
+
- underwater acoustics
|
|
27
|
+
- marine bioacoustics
|
|
28
|
+
- annotation
|
|
29
|
+
- visualization
|
|
30
|
+
- seismology
|
|
31
|
+
preferred-citation:
|
|
32
|
+
type: software
|
|
33
|
+
title: "DASexplorer: Visualisation, analysis and annotation tool for Distributed Acoustic Sensing data"
|
|
34
|
+
authors:
|
|
35
|
+
- family-names: Morell-Monzó
|
|
36
|
+
given-names: Sergio
|
|
37
|
+
version: "1.0.0"
|
|
38
|
+
year: 2026
|
|
39
|
+
doi: "10.5281/zenodo.21032550"
|
|
40
|
+
url: "https://github.com/sermomon/DASexplorer"
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024-2026 Sergio Morell-Monzó, Dídac Diego-Tortosa,
|
|
4
|
+
Isabel Pérez-Arjona, Víctor Espinosa Roselló
|
|
5
|
+
Underwater Acoustics Group (IGIC), Universitat Politècnica de València
|
|
6
|
+
|
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
in the Software without restriction, including without limitation the rights
|
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
furnished to do so, subject to the following conditions:
|
|
13
|
+
|
|
14
|
+
The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
copies or substantial portions of the Software.
|
|
16
|
+
|
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
SOFTWARE.
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: dasexplorer
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: Visualisation, analysis and annotation tool for Distributed Acoustic Sensing (DAS) data
|
|
5
|
+
Author-email: Sergio Morell-Monzó <sermomon@upv.es>
|
|
6
|
+
License: MIT License
|
|
7
|
+
|
|
8
|
+
Copyright (c) 2024-2026 Sergio Morell-Monzó, Dídac Diego-Tortosa,
|
|
9
|
+
Isabel Pérez-Arjona, Víctor Espinosa Roselló
|
|
10
|
+
Underwater Acoustics Group (IGIC), Universitat Politècnica de València
|
|
11
|
+
|
|
12
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
13
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
14
|
+
in the Software without restriction, including without limitation the rights
|
|
15
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
17
|
+
furnished to do so, subject to the following conditions:
|
|
18
|
+
|
|
19
|
+
The above copyright notice and this permission notice shall be included in all
|
|
20
|
+
copies or substantial portions of the Software.
|
|
21
|
+
|
|
22
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
23
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
24
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
25
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
26
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
27
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
28
|
+
SOFTWARE.
|
|
29
|
+
|
|
30
|
+
Project-URL: Homepage, https://github.com/sermomon/DASexplorer
|
|
31
|
+
Project-URL: Repository, https://github.com/sermomon/DASexplorer
|
|
32
|
+
Project-URL: Bug Tracker, https://github.com/sermomon/DASexplorer/issues
|
|
33
|
+
Keywords: DAS,distributed acoustic sensing,fiber optic sensing,underwater acoustics,annotation
|
|
34
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
35
|
+
Classifier: Intended Audience :: Science/Research
|
|
36
|
+
Classifier: Topic :: Scientific/Engineering :: Physics
|
|
37
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
38
|
+
Classifier: Programming Language :: Python :: 3
|
|
39
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
40
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
41
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
42
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
43
|
+
Classifier: Operating System :: OS Independent
|
|
44
|
+
Requires-Python: >=3.9
|
|
45
|
+
Description-Content-Type: text/markdown
|
|
46
|
+
License-File: LICENSE
|
|
47
|
+
Requires-Dist: PyQt5>=5.15
|
|
48
|
+
Requires-Dist: pyqtgraph>=0.13
|
|
49
|
+
Requires-Dist: numpy>=1.22
|
|
50
|
+
Requires-Dist: scipy>=1.9
|
|
51
|
+
Requires-Dist: matplotlib>=3.5
|
|
52
|
+
Requires-Dist: h5py>=3.7
|
|
53
|
+
Requires-Dist: das4whales>=0.1
|
|
54
|
+
Requires-Dist: Pillow>=9.0
|
|
55
|
+
Requires-Dist: pyyaml>=6.0
|
|
56
|
+
Provides-Extra: dev
|
|
57
|
+
Requires-Dist: build; extra == "dev"
|
|
58
|
+
Requires-Dist: twine; extra == "dev"
|
|
59
|
+
Requires-Dist: pytest; extra == "dev"
|
|
60
|
+
Dynamic: license-file
|
|
61
|
+
|
|
62
|
+
<div align="center">
|
|
63
|
+
<img src="dasexplorer/icons/icon_2.ico" alt="DASexplorer Logo" width="200"/>
|
|
64
|
+
|
|
65
|
+
<h1></h1>
|
|
66
|
+
|
|
67
|
+
<p>
|
|
68
|
+
<strong>A desktop application for visualization, analysis and annotation of Distributed Acoustic Sensing data</strong>
|
|
69
|
+
</p>
|
|
70
|
+
|
|
71
|
+
<p>
|
|
72
|
+
<a href="https://github.com/sermomon/DASexplorer/releases"><img src="https://img.shields.io/badge/release-v1.0.0-red" alt="Latest Release"/></a>
|
|
73
|
+
<a href="https://www.python.org/downloads/"><img src="https://img.shields.io/badge/python-3.10%2B-blue" alt="Python 3.10+"/></a>
|
|
74
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green" alt="MIT License"/></a>
|
|
75
|
+
<a href="https://doi.org/10.xxxx/joss.xxxxx"><img src="https://img.shields.io/badge/JOSS-paper-orange" alt="JOSS Paper"/></a>
|
|
76
|
+
<img src="https://img.shields.io/badge/platform-Windows%20%7C%20Linux%20%7C%20macOS-lightgrey" alt="Platform"/>
|
|
77
|
+
</p>
|
|
78
|
+
|
|
79
|
+
<p>
|
|
80
|
+
<a href="#installation">Installation</a> ·
|
|
81
|
+
<a href="#quickstart">Quickstart</a> ·
|
|
82
|
+
<a href="#features">Features</a> ·
|
|
83
|
+
<a href="#supported-interrogators">Interrogators</a> ·
|
|
84
|
+
<a href="#annotation-export">Annotation Export</a> ·
|
|
85
|
+
<a href="#contributing">Contributing</a> ·
|
|
86
|
+
<a href="#citation">Citation</a>
|
|
87
|
+
</p>
|
|
88
|
+
<br/>
|
|
89
|
+
|
|
90
|
+
<img src="dasexplorer/icons/screenshot.png" alt="DAS Explorer main window" width="900"/>
|
|
91
|
+
|
|
92
|
+
</div>
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
## Overview
|
|
97
|
+
|
|
98
|
+
**DASexplorer** is an open-source desktop application built for researchers working with Distributed Acoustic Sensing (DAS) data. It provides an integrated environment for loading, visualising, filtering, and annotating DAS recordings from multiple interrogator systems, without requiring any prior programming knowledge.
|
|
99
|
+
|
|
100
|
+
DASexplorer was designed for efficient interactive navigation of large DAS datasets. Built on PyQt5 and pyqtgraph, it uses spatial decimation, parameter-based caching and smart rendering strategies to handle long acquisitions with minimal memory overhead. The application is interrogator-agnostic: a profile-based configuration system maps each acquisition system to its reader, file extensions and default visualisation parameters, making it straightforward to add support for new instruments.
|
|
101
|
+
|
|
102
|
+
Key design principles:
|
|
103
|
+
|
|
104
|
+
- **No-code** — the full analysis workflow is accessible through an intuitive GUI.
|
|
105
|
+
- **Multi-interrogator** — natively supports HDAS 2.5 (Aragón Photonics), OptaSense (Luna Innovations) and OptoDAS (ASN/ Alcatel Subsea Networks) file formats; extensible to new systems.
|
|
106
|
+
- **Research-ready** — exports data and annotations in formats directly usable by machine learning and bioacoustic analysis pipelines (NPZ, MAT, YOLO, COCO JSON, Raven Pro).
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
## Citation
|
|
110
|
+
|
|
111
|
+
If you use DASexplorer in your research, please cite:
|
|
112
|
+
|
|
113
|
+
```bibtex
|
|
114
|
+
@software{morellmonzo2026dasexplorer,
|
|
115
|
+
author = {Morell-Monzó, Sergio},
|
|
116
|
+
title = {DASexplorer},
|
|
117
|
+
version = {1.0},
|
|
118
|
+
year = {2026},
|
|
119
|
+
publisher = {Zenodo},
|
|
120
|
+
doi = {10.5281/zenodo.21032550},
|
|
121
|
+
url = {https://doi.org/10.5281/zenodo.21032550}
|
|
122
|
+
}
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
[](https://doi.org/10.5281/zenodo.21032550)
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
<img src="dasexplorer/icons/icon_2.ico" alt="DASexplorer Logo" width="200"/>
|
|
3
|
+
|
|
4
|
+
<h1></h1>
|
|
5
|
+
|
|
6
|
+
<p>
|
|
7
|
+
<strong>A desktop application for visualization, analysis and annotation of Distributed Acoustic Sensing data</strong>
|
|
8
|
+
</p>
|
|
9
|
+
|
|
10
|
+
<p>
|
|
11
|
+
<a href="https://github.com/sermomon/DASexplorer/releases"><img src="https://img.shields.io/badge/release-v1.0.0-red" alt="Latest Release"/></a>
|
|
12
|
+
<a href="https://www.python.org/downloads/"><img src="https://img.shields.io/badge/python-3.10%2B-blue" alt="Python 3.10+"/></a>
|
|
13
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-green" alt="MIT License"/></a>
|
|
14
|
+
<a href="https://doi.org/10.xxxx/joss.xxxxx"><img src="https://img.shields.io/badge/JOSS-paper-orange" alt="JOSS Paper"/></a>
|
|
15
|
+
<img src="https://img.shields.io/badge/platform-Windows%20%7C%20Linux%20%7C%20macOS-lightgrey" alt="Platform"/>
|
|
16
|
+
</p>
|
|
17
|
+
|
|
18
|
+
<p>
|
|
19
|
+
<a href="#installation">Installation</a> ·
|
|
20
|
+
<a href="#quickstart">Quickstart</a> ·
|
|
21
|
+
<a href="#features">Features</a> ·
|
|
22
|
+
<a href="#supported-interrogators">Interrogators</a> ·
|
|
23
|
+
<a href="#annotation-export">Annotation Export</a> ·
|
|
24
|
+
<a href="#contributing">Contributing</a> ·
|
|
25
|
+
<a href="#citation">Citation</a>
|
|
26
|
+
</p>
|
|
27
|
+
<br/>
|
|
28
|
+
|
|
29
|
+
<img src="dasexplorer/icons/screenshot.png" alt="DAS Explorer main window" width="900"/>
|
|
30
|
+
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## Overview
|
|
36
|
+
|
|
37
|
+
**DASexplorer** is an open-source desktop application built for researchers working with Distributed Acoustic Sensing (DAS) data. It provides an integrated environment for loading, visualising, filtering, and annotating DAS recordings from multiple interrogator systems, without requiring any prior programming knowledge.
|
|
38
|
+
|
|
39
|
+
DASexplorer was designed for efficient interactive navigation of large DAS datasets. Built on PyQt5 and pyqtgraph, it uses spatial decimation, parameter-based caching and smart rendering strategies to handle long acquisitions with minimal memory overhead. The application is interrogator-agnostic: a profile-based configuration system maps each acquisition system to its reader, file extensions and default visualisation parameters, making it straightforward to add support for new instruments.
|
|
40
|
+
|
|
41
|
+
Key design principles:
|
|
42
|
+
|
|
43
|
+
- **No-code** — the full analysis workflow is accessible through an intuitive GUI.
|
|
44
|
+
- **Multi-interrogator** — natively supports HDAS 2.5 (Aragón Photonics), OptaSense (Luna Innovations) and OptoDAS (ASN/ Alcatel Subsea Networks) file formats; extensible to new systems.
|
|
45
|
+
- **Research-ready** — exports data and annotations in formats directly usable by machine learning and bioacoustic analysis pipelines (NPZ, MAT, YOLO, COCO JSON, Raven Pro).
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
## Citation
|
|
49
|
+
|
|
50
|
+
If you use DASexplorer in your research, please cite:
|
|
51
|
+
|
|
52
|
+
```bibtex
|
|
53
|
+
@software{morellmonzo2026dasexplorer,
|
|
54
|
+
author = {Morell-Monzó, Sergio},
|
|
55
|
+
title = {DASexplorer},
|
|
56
|
+
version = {1.0},
|
|
57
|
+
year = {2026},
|
|
58
|
+
publisher = {Zenodo},
|
|
59
|
+
doi = {10.5281/zenodo.21032550},
|
|
60
|
+
url = {https://doi.org/10.5281/zenodo.21032550}
|
|
61
|
+
}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
[](https://doi.org/10.5281/zenodo.21032550)
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"""
|
|
2
|
+
DAS Explorer - entry point.
|
|
3
|
+
|
|
4
|
+
Run with:
|
|
5
|
+
python -m dasexplorer
|
|
6
|
+
or after pip install:
|
|
7
|
+
dasexplorer
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
import os
|
|
11
|
+
|
|
12
|
+
os.environ.setdefault("PYQTGRAPH_QT_LIB", "PyQt5")
|
|
13
|
+
|
|
14
|
+
import sys
|
|
15
|
+
|
|
16
|
+
import pyqtgraph as pg
|
|
17
|
+
from PyQt5 import QtWidgets, QtGui
|
|
18
|
+
|
|
19
|
+
from dasexplorer.gui.main_window import MainWindow
|
|
20
|
+
from dasexplorer.gui import theme as theme_mod
|
|
21
|
+
from dasexplorer.core.config import get_ui_defaults
|
|
22
|
+
from dasexplorer.version import __version__
|
|
23
|
+
|
|
24
|
+
pg.setConfigOptions(imageAxisOrder="row-major", antialias=False)
|
|
25
|
+
|
|
26
|
+
DARK_STYLESHEET = theme_mod.build_stylesheet(theme_mod.DARK)
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
def main():
|
|
30
|
+
if sys.platform == "win32":
|
|
31
|
+
import ctypes
|
|
32
|
+
try:
|
|
33
|
+
ctypes.windll.shell32.SetCurrentProcessExplicitAppUserModelID(
|
|
34
|
+
"IGIC-UPV.DASExplorer." + __version__
|
|
35
|
+
)
|
|
36
|
+
except Exception:
|
|
37
|
+
pass
|
|
38
|
+
|
|
39
|
+
app = QtWidgets.QApplication(sys.argv)
|
|
40
|
+
|
|
41
|
+
ui_cfg = get_ui_defaults()
|
|
42
|
+
saved_theme = str(ui_cfg.get("theme", "dark")).lower()
|
|
43
|
+
theme = theme_mod.set_current(saved_theme if saved_theme in theme_mod.THEMES else "dark")
|
|
44
|
+
pg.setConfigOption("background", theme["pg_background"])
|
|
45
|
+
pg.setConfigOption("foreground", theme["pg_foreground"])
|
|
46
|
+
app.setStyleSheet(theme_mod.build_stylesheet(theme))
|
|
47
|
+
|
|
48
|
+
# Icon path relative to the installed package location
|
|
49
|
+
icon_dir = os.path.dirname(os.path.abspath(__file__))
|
|
50
|
+
taskbar_icon_path = os.path.join(icon_dir, "icons", "icon_2.ico")
|
|
51
|
+
if os.path.isfile(taskbar_icon_path):
|
|
52
|
+
app.setWindowIcon(QtGui.QIcon(taskbar_icon_path))
|
|
53
|
+
|
|
54
|
+
win = MainWindow()
|
|
55
|
+
win.showMaximized()
|
|
56
|
+
sys.exit(app.exec_())
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
if __name__ == "__main__":
|
|
60
|
+
main()
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"_comment": "DAS Explorer configuration. Each profile defines an interrogator + visualisation defaults.",
|
|
3
|
+
"_comment2": "null means 'use full range from file'. Add new profiles by duplicating an existing block.",
|
|
4
|
+
"default_profile": "hdas25_default",
|
|
5
|
+
"profiles": {
|
|
6
|
+
"hdas25_default": {
|
|
7
|
+
"label": "HDAS 2.5 (.bin) Default",
|
|
8
|
+
"interrogator": "hdas2.5",
|
|
9
|
+
"file_extensions": [
|
|
10
|
+
".bin"
|
|
11
|
+
],
|
|
12
|
+
"num_files": 1,
|
|
13
|
+
"tmin_s": null,
|
|
14
|
+
"tmax_s": null,
|
|
15
|
+
"dmin_m": null,
|
|
16
|
+
"dmax_m": null,
|
|
17
|
+
"vmin": 0.0,
|
|
18
|
+
"vmax": 12.0,
|
|
19
|
+
"colormap": "Rainbow",
|
|
20
|
+
"fmin_hz": 1.0,
|
|
21
|
+
"fmax_hz": null,
|
|
22
|
+
"fmax_offset_hz": 0.01,
|
|
23
|
+
"stride": 1,
|
|
24
|
+
"envelope": false,
|
|
25
|
+
"fk_cmin_ms": 100.0,
|
|
26
|
+
"fk_cmax_ms": 100000.0,
|
|
27
|
+
"fk_fmin_hz": 1.0,
|
|
28
|
+
"fk_fmax_hz": null,
|
|
29
|
+
"fk_fmax_offset_hz": 0.01,
|
|
30
|
+
"fk_envelope": false,
|
|
31
|
+
"default_view": "raw",
|
|
32
|
+
"rgb_rmin_hz": 1.0,
|
|
33
|
+
"rgb_rmax_hz": 5.0,
|
|
34
|
+
"rgb_gmin_hz": 5.0,
|
|
35
|
+
"rgb_gmax_hz": 15.0,
|
|
36
|
+
"rgb_bmin_hz": 15.0,
|
|
37
|
+
"rgb_bmax_hz": 40.0,
|
|
38
|
+
"rgb_percentile": 90.0
|
|
39
|
+
},
|
|
40
|
+
"optasense_default": {
|
|
41
|
+
"label": "OptaSense (.h5) Default",
|
|
42
|
+
"interrogator": "optasense",
|
|
43
|
+
"file_extensions": [
|
|
44
|
+
".h5",
|
|
45
|
+
".hdf5"
|
|
46
|
+
],
|
|
47
|
+
"tmin_s": null,
|
|
48
|
+
"tmax_s": null,
|
|
49
|
+
"dmin_m": null,
|
|
50
|
+
"dmax_m": null,
|
|
51
|
+
"vmin": 0.0,
|
|
52
|
+
"vmax": 0.4,
|
|
53
|
+
"colormap": "Rainbow",
|
|
54
|
+
"fmin_hz": 10.0,
|
|
55
|
+
"fmax_hz": null,
|
|
56
|
+
"fmax_offset_hz": 0.01,
|
|
57
|
+
"stride": 1,
|
|
58
|
+
"envelope": true,
|
|
59
|
+
"fk_cmin_ms": 1400.0,
|
|
60
|
+
"fk_cmax_ms": 3500.0,
|
|
61
|
+
"fk_fmin_hz": 10.0,
|
|
62
|
+
"fk_fmax_hz": null,
|
|
63
|
+
"fk_fmax_offset_hz": 0.01,
|
|
64
|
+
"fk_envelope": true,
|
|
65
|
+
"default_view": "raw",
|
|
66
|
+
"rgb_rmin_hz": 1.0,
|
|
67
|
+
"rgb_rmax_hz": 5.0,
|
|
68
|
+
"rgb_gmin_hz": 5.0,
|
|
69
|
+
"rgb_gmax_hz": 15.0,
|
|
70
|
+
"rgb_bmin_hz": 15.0,
|
|
71
|
+
"rgb_bmax_hz": 40.0,
|
|
72
|
+
"rgb_percentile": 90.0,
|
|
73
|
+
"num_files": 1
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
"ui": {
|
|
77
|
+
"_comment": "App-wide UI settings (independent of profile).",
|
|
78
|
+
"colormap": "Rainbow",
|
|
79
|
+
"panel_width_fraction": 0.2,
|
|
80
|
+
"theme": "dark"
|
|
81
|
+
}
|
|
82
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Analysis functions for DAS Explorer annotation windows.
|
|
3
|
+
|
|
4
|
+
All functions operate on numpy arrays and return plain numpy results,
|
|
5
|
+
with no Qt or pyqtgraph dependency.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
import numpy as np
|
|
9
|
+
import scipy.signal as sp
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
def compute_spectrogram(signal: np.ndarray, fs: float,
|
|
13
|
+
nperseg: int = 256, noverlap: int = None,
|
|
14
|
+
nfft: int = None):
|
|
15
|
+
"""
|
|
16
|
+
Compute the spectrogram of a 1-D signal (PSD, dB scale).
|
|
17
|
+
|
|
18
|
+
Returns
|
|
19
|
+
-------
|
|
20
|
+
f : np.ndarray frequency axis [Hz]
|
|
21
|
+
t : np.ndarray time axis [s]
|
|
22
|
+
Sxx_db : np.ndarray (n_freq, n_time) power in dB
|
|
23
|
+
"""
|
|
24
|
+
n_samples = len(signal)
|
|
25
|
+
|
|
26
|
+
# Clamp nperseg to the number of available samples.
|
|
27
|
+
nperseg = min(nperseg, n_samples)
|
|
28
|
+
|
|
29
|
+
if noverlap is None:
|
|
30
|
+
noverlap = nperseg // 2
|
|
31
|
+
else:
|
|
32
|
+
# Clamp noverlap: must be strictly less than (possibly clamped) nperseg.
|
|
33
|
+
noverlap = min(noverlap, nperseg - 1)
|
|
34
|
+
|
|
35
|
+
if nfft is None:
|
|
36
|
+
nfft = nperseg
|
|
37
|
+
else:
|
|
38
|
+
nfft = max(nfft, nperseg) # nfft must be >= nperseg
|
|
39
|
+
|
|
40
|
+
f, t, Sxx = sp.spectrogram(
|
|
41
|
+
signal, fs=fs,
|
|
42
|
+
nperseg=nperseg, noverlap=noverlap, nfft=nfft,
|
|
43
|
+
window='hann', scaling='density',
|
|
44
|
+
)
|
|
45
|
+
Sxx_db = 10.0 * np.log10(np.maximum(Sxx, 1e-20))
|
|
46
|
+
return f, t, Sxx_db
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
def compute_spectrum(signal: np.ndarray, fs: float,
|
|
50
|
+
nfft: int = 2048,
|
|
51
|
+
window: str = 'hann') -> tuple:
|
|
52
|
+
"""
|
|
53
|
+
Compute the magnitude spectrum of a 1-D signal.
|
|
54
|
+
|
|
55
|
+
Returns
|
|
56
|
+
-------
|
|
57
|
+
freqs : np.ndarray frequency axis [Hz]
|
|
58
|
+
mag : np.ndarray magnitude spectrum
|
|
59
|
+
"""
|
|
60
|
+
n = len(signal)
|
|
61
|
+
if window == 'hann':
|
|
62
|
+
w = np.hanning(n)
|
|
63
|
+
elif window == 'hamming':
|
|
64
|
+
w = np.hamming(n)
|
|
65
|
+
elif window == 'blackman':
|
|
66
|
+
w = np.blackman(n)
|
|
67
|
+
elif window == 'bartlett':
|
|
68
|
+
w = np.bartlett(n)
|
|
69
|
+
else:
|
|
70
|
+
w = np.ones(n)
|
|
71
|
+
|
|
72
|
+
F = np.fft.rfft(signal * w, n=nfft)
|
|
73
|
+
mag = np.abs(F)
|
|
74
|
+
freqs = np.fft.rfftfreq(nfft, d=1.0 / fs)
|
|
75
|
+
return freqs, mag
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
def select_channels_for_spectral(di0: int, di1: int,
|
|
79
|
+
max_n: int = 30) -> list:
|
|
80
|
+
"""
|
|
81
|
+
Return up to max_n channel indices uniformly sampled in [di0, di1).
|
|
82
|
+
"""
|
|
83
|
+
n = di1 - di0
|
|
84
|
+
if n <= 0:
|
|
85
|
+
return [di0]
|
|
86
|
+
if n <= max_n:
|
|
87
|
+
return list(range(di0, di1))
|
|
88
|
+
idx = np.round(np.linspace(di0, di1 - 1, max_n)).astype(int)
|
|
89
|
+
return sorted(set(idx.tolist()))
|