arcjetCV 1.1.4.dev5__tar.gz → 1.1.4.dev6__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 (59) hide show
  1. {arcjetcv-1.1.4.dev5/arcjetcv.egg-info → arcjetcv-1.1.4.dev6}/PKG-INFO +1 -1
  2. arcjetcv-1.1.4.dev6/arcjetCV/segmentation/contour/model_loader.py +76 -0
  3. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6/arcjetcv.egg-info}/PKG-INFO +1 -1
  4. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/setup.py +1 -1
  5. arcjetcv-1.1.4.dev5/arcjetCV/segmentation/contour/model_loader.py +0 -20
  6. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/LICENSE +0 -0
  7. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/MANIFEST.in +0 -0
  8. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/README.md +0 -0
  9. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/README_pypi.md +0 -0
  10. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/__init__.py +0 -0
  11. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/__init__.py +0 -0
  12. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/calibrate_video.py +0 -0
  13. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/calibration_controller.py +0 -0
  14. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/calibration_main.py +0 -0
  15. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/calibration_model.py +0 -0
  16. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/calibration_view.py +0 -0
  17. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/chessboard_pattern.png +0 -0
  18. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/detetct_example.py +0 -0
  19. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/rotated_pattern.png +0 -0
  20. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/calibration/test.py +0 -0
  21. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/chessboard_pattern.png +0 -0
  22. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/__init__.py +0 -0
  23. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/_arcjetCV_gui.py +0 -0
  24. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/arcjetCV_gui.py +0 -0
  25. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/custom_classes.py +0 -0
  26. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/logo/arcjetCV_logo.icns +0 -0
  27. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/logo/arcjetCV_logo.ico +0 -0
  28. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/logo/arcjetCV_logo_.png +0 -0
  29. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/logo/arcjetCV_logo_white.png +0 -0
  30. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/main.py +0 -0
  31. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/gui/main_window.py +0 -0
  32. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/__init__.py +0 -0
  33. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/contour/__init__.py +0 -0
  34. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/contour/cnn.py +0 -0
  35. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/contour/contour.py +0 -0
  36. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/contour/conversion.py +0 -0
  37. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/time/__init__.py +0 -0
  38. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/segmentation/time/time_segmentation.py +0 -0
  39. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/__init__.py +0 -0
  40. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/logger.py +0 -0
  41. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/output.py +0 -0
  42. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/processor.py +0 -0
  43. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/utils.py +0 -0
  44. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetCV/utils/video.py +0 -0
  45. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetcv.egg-info/SOURCES.txt +0 -0
  46. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetcv.egg-info/dependency_links.txt +0 -0
  47. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetcv.egg-info/entry_points.txt +0 -0
  48. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetcv.egg-info/requires.txt +0 -0
  49. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/arcjetcv.egg-info/top_level.txt +0 -0
  50. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/setup.cfg +0 -0
  51. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/README.md +0 -0
  52. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/__init__.py +0 -0
  53. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/chessboard_pattern.png +0 -0
  54. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_calibration_functions.py +0 -0
  55. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_calibration_gui.py +0 -0
  56. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_functions.py +0 -0
  57. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_gui.py +0 -0
  58. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_obj_models.py +0 -0
  59. {arcjetcv-1.1.4.dev5 → arcjetcv-1.1.4.dev6}/tests/test_segmentation.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: arcjetcv
3
- Version: 1.1.4.dev5
3
+ Version: 1.1.4.dev6
4
4
  Summary: Package to process arcjet videos and segment the edge of the shock and of the sample
5
5
  Home-page: https://github.com/magnus-haw/arcjetCV
6
6
  Author: arcjetCV team
@@ -0,0 +1,76 @@
1
+ import urllib.request
2
+ from pathlib import Path
3
+ import os
4
+ from PySide6.QtWidgets import (
5
+ QApplication,
6
+ QMessageBox,
7
+ QDialog,
8
+ QVBoxLayout,
9
+ QLabel,
10
+ QProgressBar,
11
+ )
12
+ from PySide6.QtCore import Qt, QThread, Signal
13
+
14
+
15
+ class DownloadThread(QThread):
16
+ progress = Signal(int)
17
+ error = Signal(str)
18
+ finished = Signal()
19
+
20
+ def __init__(self, url, output_path):
21
+ super().__init__()
22
+ self.url = url
23
+ self.output_path = output_path
24
+
25
+ def run(self):
26
+ try:
27
+
28
+ def reporthook(blocknum, blocksize, totalsize):
29
+ readsofar = blocknum * blocksize
30
+ percent = int(readsofar * 100 / totalsize) if totalsize > 0 else 0
31
+ self.progress.emit(min(percent, 100))
32
+
33
+ urllib.request.urlretrieve(self.url, self.output_path, reporthook)
34
+ self.finished.emit()
35
+ except Exception as e:
36
+ self.error.emit(str(e))
37
+
38
+
39
+ class DownloadPopup(QDialog):
40
+ def __init__(self, url, output_path):
41
+ super().__init__()
42
+ self.setWindowTitle("Downloading Model Weights")
43
+ self.setWindowFlags(self.windowFlags() | Qt.CustomizeWindowHint)
44
+ self.setWindowFlags(self.windowFlags() & ~Qt.WindowCloseButtonHint)
45
+
46
+ self.layout = QVBoxLayout()
47
+ self.label = QLabel("Downloading model weights, please wait...")
48
+ self.progress_bar = QProgressBar()
49
+ self.progress_bar.setRange(0, 100)
50
+ self.layout.addWidget(self.label)
51
+ self.layout.addWidget(self.progress_bar)
52
+ self.setLayout(self.layout)
53
+
54
+ self.thread = DownloadThread(url, output_path)
55
+ self.thread.progress.connect(self.progress_bar.setValue)
56
+ self.thread.error.connect(self.show_error)
57
+ self.thread.finished.connect(self.accept)
58
+ self.thread.start()
59
+
60
+ def show_error(self, message):
61
+ QMessageBox.critical(self, "Download Failed", f"❌ {message}")
62
+ self.reject()
63
+
64
+
65
+ def get_model_checkpoint():
66
+ model_name = "Unet-xception_25_weights_only.pt"
67
+ checkpoint_path = Path(__file__).parent / model_name
68
+ if not checkpoint_path.exists():
69
+ url = "https://github.com/magnus-haw/arcjetCV/raw/main/arcjetCV/segmentation/contour/Unet-xception_25_weights_only.pt"
70
+
71
+ app = QApplication.instance() or QApplication([])
72
+ popup = DownloadPopup(url, str(checkpoint_path))
73
+ if not popup.exec():
74
+ raise RuntimeError("Download canceled or failed.")
75
+
76
+ return checkpoint_path
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: arcjetcv
3
- Version: 1.1.4.dev5
3
+ Version: 1.1.4.dev6
4
4
  Summary: Package to process arcjet videos and segment the edge of the shock and of the sample
5
5
  Home-page: https://github.com/magnus-haw/arcjetCV
6
6
  Author: arcjetCV team
@@ -66,7 +66,7 @@ check_linux_dependencies()
66
66
  # Define the setup configuration
67
67
  setup(
68
68
  name="arcjetcv",
69
- version="1.1.4.dev5", # Set the version directly here
69
+ version="1.1.4.dev6", # Set the version directly here
70
70
  author="arcjetCV team",
71
71
  description="Package to process arcjet videos and segment the edge of the shock and of the sample",
72
72
  long_description=long_description,
@@ -1,20 +0,0 @@
1
- import urllib.request
2
- from pathlib import Path
3
- import os
4
-
5
-
6
- def get_model_checkpoint():
7
- print("Checking the model checkpoint")
8
- model_name = "Unet-xception_25_weights_only.pt"
9
- checkpoint_path = Path(__file__).parent / model_name
10
- print(f"Checkpoint path: {checkpoint_path}")
11
-
12
- if not checkpoint_path.exists():
13
- print(f"[INFO] Downloading model weights to {checkpoint_path}...")
14
- url = "https://github.com/magnus-haw/arcjetCV/raw/main/arcjetCV/segmentation/contour/Unet-xception_25_weights_only.pt"
15
- try:
16
- urllib.request.urlretrieve(url, checkpoint_path)
17
- except Exception as e:
18
- raise RuntimeError(f"❌ Failed to download model weights: {e}")
19
-
20
- return checkpoint_path
File without changes
File without changes
File without changes
File without changes