xttmp 2.3.0.4__tar.gz → 2.3.0.5__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.
- {xttmp-2.3.0.4/src/xttmp.egg-info → xttmp-2.3.0.5}/PKG-INFO +2 -2
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/README.md +1 -1
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/pyproject.toml +1 -1
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/math_operator.py +12 -4
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/demo/inference_gui.py +4 -6
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/main.py +0 -8
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/haarstmd.py +1 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/iostream.py +3 -3
- {xttmp-2.3.0.4 → xttmp-2.3.0.5/src/xttmp.egg-info}/PKG-INFO +2 -2
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/LICENSE +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/setup.cfg +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/__init__.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/api/__init__.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/api/evaluate.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/api/get_visualize_handle.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/api/instancing_model.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/__init__.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/apgstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/apgstmdv2_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/base_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/dstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/estmd_backbone.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/estmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/feedbackstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/fracstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/fstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/fstmdv2_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/haarstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/stfeedbackstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/stmdplus_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/stmdplusv2_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/core/vstmd_core.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/demo/evaluate_model.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/demo/inference_gui_single_process.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/demo/inference_image_stream.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/demo/inference_video.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/__init__.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/backbone.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/facilitated_model.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/feedback_model.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/model/vstmd.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/__init__.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/compute_module.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/create_kernel.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/evaluate_module.py +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp/util/stmd.ico +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp.egg-info/SOURCES.txt +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp.egg-info/dependency_links.txt +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp.egg-info/entry_points.txt +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp.egg-info/requires.txt +0 -0
- {xttmp-2.3.0.4 → xttmp-2.3.0.5}/src/xttmp.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: xttmp
|
|
3
|
-
Version: 2.3.0.
|
|
3
|
+
Version: 2.3.0.5
|
|
4
4
|
Summary: eXtremely Tiny Target - Motion Perception
|
|
5
5
|
Author-email: Shawn MX <mingshuoxu@hotmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/MingshuoXu/Small-Target-Motion-Detectors
|
|
@@ -30,7 +30,7 @@ Dynamic: license-file
|
|
|
30
30
|
|
|
31
31
|
# Small Target Motion Detectors, Version 2.3 (XTT-MP: Extremely Tiny Target - Motion Perception)
|
|
32
32
|
|
|
33
|
-
[](https://pypi.org/project/xttmp/) [](LICENSE) [](https://www.python.org/) [](https://pytorch.org/)
|
|
34
34
|
|
|
35
35
|
|
|
36
36
|
**XTT-MP** (Extremely Tiny Target - Motion Perception) is a natural architecture-based framework specifically designed for detecting and perceiving the motion of **extremely small targets** in complex environments.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Small Target Motion Detectors, Version 2.3 (XTT-MP: Extremely Tiny Target - Motion Perception)
|
|
2
2
|
|
|
3
|
-
[](https://pypi.org/project/xttmp/) [](LICENSE) [](https://www.python.org/) [](https://pytorch.org/)
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
**XTT-MP** (Extremely Tiny Target - Motion Perception) is a natural architecture-based framework specifically designed for detecting and perceiving the motion of **extremely small targets** in complex environments.
|
|
@@ -102,7 +102,9 @@ class GaussianBlur(BaseCore):
|
|
|
102
102
|
weight = self.blur_kernel.expand(C, 1, self.kernel_size, self.kernel_size)
|
|
103
103
|
|
|
104
104
|
# 使用深度可分离卷积(groups=C),每个通道独立进行高斯模糊
|
|
105
|
-
|
|
105
|
+
self.output = F.conv2d(x, weight, padding='same', groups=C)
|
|
106
|
+
|
|
107
|
+
return self.output
|
|
106
108
|
|
|
107
109
|
|
|
108
110
|
class GammaDelay(BaseCore):
|
|
@@ -161,7 +163,9 @@ class GammaDelay(BaseCore):
|
|
|
161
163
|
else:
|
|
162
164
|
self.buffer.append(x)
|
|
163
165
|
|
|
164
|
-
|
|
166
|
+
self.output = compute_temporal_conv_inplace(self.buffer, self.gamma_kernel)
|
|
167
|
+
|
|
168
|
+
return self.output
|
|
165
169
|
|
|
166
170
|
|
|
167
171
|
class GammaBandPassFilter(BaseCore):
|
|
@@ -236,7 +240,9 @@ class GammaBandPassFilter(BaseCore):
|
|
|
236
240
|
else:
|
|
237
241
|
self.buffer.append(x)
|
|
238
242
|
|
|
239
|
-
|
|
243
|
+
self.output = compute_temporal_conv_inplace(self.buffer, self.bandpass_kernel)
|
|
244
|
+
|
|
245
|
+
return self.output
|
|
240
246
|
|
|
241
247
|
|
|
242
248
|
class SpatialInhibition(BaseCore):
|
|
@@ -304,4 +310,6 @@ class SpatialInhibition(BaseCore):
|
|
|
304
310
|
weight = self.kernel.expand(C, 1, self.kernel_size, self.kernel_size)
|
|
305
311
|
|
|
306
312
|
# groups=C 表示进行深度可分离卷积(Depthwise Convolution),每个通道独立滤波
|
|
307
|
-
|
|
313
|
+
self.output = F.relu(F.conv2d(x, weight, padding='same', groups=C))
|
|
314
|
+
|
|
315
|
+
return self.output
|
|
@@ -18,9 +18,6 @@ from xttmp.util.iostream import ( # type: ignore
|
|
|
18
18
|
FrameIterator,
|
|
19
19
|
FrameVisualizer,
|
|
20
20
|
)
|
|
21
|
-
from xttmp.api import instancing_model
|
|
22
|
-
|
|
23
|
-
|
|
24
21
|
# configure logging
|
|
25
22
|
logging.basicConfig(level=logging.INFO,
|
|
26
23
|
format='%(asctime)s - %(levelname)s - %(message)s')
|
|
@@ -34,7 +31,6 @@ class StmdGui:
|
|
|
34
31
|
self.FrameIterator = FrameIterator
|
|
35
32
|
self.FrameVisualizer = FrameVisualizer
|
|
36
33
|
self.post_processor = None
|
|
37
|
-
self.instancing_model = instancing_model
|
|
38
34
|
|
|
39
35
|
def _get_user_input(self) -> tuple:
|
|
40
36
|
""" get user input """
|
|
@@ -89,7 +85,9 @@ class StmdGui:
|
|
|
89
85
|
self.post_processor = post_processor
|
|
90
86
|
self.device = device
|
|
91
87
|
reader = self._create_frame_reader(opt1, opt2)
|
|
92
|
-
|
|
88
|
+
|
|
89
|
+
from xttmp.api import instancing_model
|
|
90
|
+
model = instancing_model(model_name, device)
|
|
93
91
|
|
|
94
92
|
visualizer = self.FrameVisualizer(
|
|
95
93
|
window_name=model_name,
|
|
@@ -114,7 +112,7 @@ class StmdGui:
|
|
|
114
112
|
run_time = time.perf_counter() - time_start
|
|
115
113
|
|
|
116
114
|
post_res = post_processor(result['response'], result.get('direction'))
|
|
117
|
-
show_str = f'{self.device} : {run_time*1000:.1f} ms'
|
|
115
|
+
show_str = f'{self.device.upper()} : {run_time*1000:.1f} ms'
|
|
118
116
|
if not visualizer.update(color_img, result=post_res, show_str=show_str):
|
|
119
117
|
break
|
|
120
118
|
|
|
@@ -2,14 +2,6 @@ from pathlib import Path
|
|
|
2
2
|
import subprocess
|
|
3
3
|
import sys
|
|
4
4
|
|
|
5
|
-
try:
|
|
6
|
-
import torch
|
|
7
|
-
except ImportError:
|
|
8
|
-
raise ImportError(
|
|
9
|
-
"Please install PyTorch first. "
|
|
10
|
-
"See https://pytorch.org/get-started/locally/"
|
|
11
|
-
)
|
|
12
|
-
|
|
13
5
|
def main():
|
|
14
6
|
script_path = Path(__file__).resolve().parent / 'demo' / 'inference_gui.py'
|
|
15
7
|
result = subprocess.run([sys.executable, str(script_path)], check=False)
|
|
@@ -451,7 +451,7 @@ class ModelSelectorGUI:
|
|
|
451
451
|
self.root = root
|
|
452
452
|
|
|
453
453
|
def create_gui(self, modelList):
|
|
454
|
-
self.modelLabel = ttk.Label(self.root, text="Select
|
|
454
|
+
self.modelLabel = ttk.Label(self.root, text="Select A Model:", width = 15)
|
|
455
455
|
self.modelLabel.grid(row=0, column=0, padx=10, pady=10)
|
|
456
456
|
|
|
457
457
|
self.modelCombobox = ttk.Combobox(self.root, values=modelList, width = 25)
|
|
@@ -596,14 +596,14 @@ class PostProcessingSelectorGUI:
|
|
|
596
596
|
self.selectedOption = tk.IntVar(value=2)
|
|
597
597
|
|
|
598
598
|
self.dotLabel = ttk.Radiobutton(self.root,
|
|
599
|
-
text='
|
|
599
|
+
text='STMD Output',
|
|
600
600
|
variable=self.selectedOption,
|
|
601
601
|
value=2,
|
|
602
602
|
command=self.select_dot)
|
|
603
603
|
self.dotLabel.grid(row=5, column=1, padx=10, pady=10, sticky="w")
|
|
604
604
|
|
|
605
605
|
self.bboxLabel = ttk.Radiobutton(self.root,
|
|
606
|
-
text='
|
|
606
|
+
text='Bbox Output',
|
|
607
607
|
variable=self.selectedOption,
|
|
608
608
|
value=1,
|
|
609
609
|
command=self.select_bbox)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: xttmp
|
|
3
|
-
Version: 2.3.0.
|
|
3
|
+
Version: 2.3.0.5
|
|
4
4
|
Summary: eXtremely Tiny Target - Motion Perception
|
|
5
5
|
Author-email: Shawn MX <mingshuoxu@hotmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/MingshuoXu/Small-Target-Motion-Detectors
|
|
@@ -30,7 +30,7 @@ Dynamic: license-file
|
|
|
30
30
|
|
|
31
31
|
# Small Target Motion Detectors, Version 2.3 (XTT-MP: Extremely Tiny Target - Motion Perception)
|
|
32
32
|
|
|
33
|
-
[](https://pypi.org/project/xttmp/) [](LICENSE) [](https://www.python.org/) [](https://pytorch.org/)
|
|
34
34
|
|
|
35
35
|
|
|
36
36
|
**XTT-MP** (Extremely Tiny Target - Motion Perception) is a natural architecture-based framework specifically designed for detecting and perceiving the motion of **extremely small targets** in complex environments.
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|