hjxdl 0.3.48__py3-none-any.whl → 0.3.50__py3-none-any.whl
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.
- hdl/_version.py +2 -2
- hdl/utils/vis_tools/scene_detect.py +8 -5
- {hjxdl-0.3.48.dist-info → hjxdl-0.3.50.dist-info}/METADATA +1 -1
- {hjxdl-0.3.48.dist-info → hjxdl-0.3.50.dist-info}/RECORD +7 -7
- {hjxdl-0.3.48.dist-info → hjxdl-0.3.50.dist-info}/WHEEL +0 -0
- {hjxdl-0.3.48.dist-info → hjxdl-0.3.50.dist-info}/licenses/LICENSE +0 -0
- {hjxdl-0.3.48.dist-info → hjxdl-0.3.50.dist-info}/top_level.txt +0 -0
hdl/_version.py
CHANGED
@@ -138,14 +138,15 @@ def fill_descriptions(
|
|
138
138
|
client,
|
139
139
|
input_json,
|
140
140
|
output_json,
|
141
|
-
output_dir
|
141
|
+
output_dir,
|
142
|
+
model
|
142
143
|
):
|
143
144
|
with open(input_json, "r", encoding="utf-8") as f:
|
144
145
|
scenes = json.load(f)
|
145
146
|
|
146
147
|
for scene in tqdm(scenes, desc="生成场景描述"):
|
147
148
|
img_path = os.path.join(output_dir, scene["image"])
|
148
|
-
scene["description"] = describe_image(img_path, client=client)
|
149
|
+
scene["description"] = describe_image(img_path, client=client, model=model)
|
149
150
|
scene.pop("image", None)
|
150
151
|
|
151
152
|
with open(output_json, "w", encoding="utf-8") as f:
|
@@ -171,7 +172,7 @@ class SceneDetector(object):
|
|
171
172
|
|
172
173
|
if not self.temp_json:
|
173
174
|
self.temp_json = self.video_file + ".tmp.json"
|
174
|
-
if not self.final_json
|
175
|
+
if not self.final_json:
|
175
176
|
self.final_json = self.video_file + ".final.json"
|
176
177
|
|
177
178
|
if self.pre_processsing:
|
@@ -182,7 +183,8 @@ class SceneDetector(object):
|
|
182
183
|
|
183
184
|
def detect(
|
184
185
|
self,
|
185
|
-
out_dir
|
186
|
+
out_dir,
|
187
|
+
model
|
186
188
|
):
|
187
189
|
output_csv = detect_scenes_cli(self.video_file, out_dir)
|
188
190
|
# df = pd.read_csv(output_csv, skiprows=1)
|
@@ -193,6 +195,7 @@ class SceneDetector(object):
|
|
193
195
|
fill_descriptions(
|
194
196
|
self.temp_json,
|
195
197
|
self.final_json,
|
196
|
-
out_dir
|
198
|
+
out_dir,
|
199
|
+
model=model
|
197
200
|
)
|
198
201
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
hdl/__init__.py,sha256=GffnD0jLJdhkd-vo989v40N90sQbofkayRBwxc6TVhQ,72
|
2
|
-
hdl/_version.py,sha256=
|
2
|
+
hdl/_version.py,sha256=4lAmGHabwGRQzA7ZW_pkNIohlJzGsK8zlLuDaIGyYKE,513
|
3
3
|
hdl/args/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
4
4
|
hdl/args/loss_args.py,sha256=s7YzSdd7IjD24rZvvOrxLLFqMZQb9YylxKeyelSdrTk,70
|
5
5
|
hdl/controllers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
@@ -143,11 +143,11 @@ hdl/utils/llm/visrag.py,sha256=0i-VrxqgiV-J7R3VPshu9oc7-rKjFJOldYik3HDXj6M,10176
|
|
143
143
|
hdl/utils/schedulers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
144
144
|
hdl/utils/schedulers/norm_lr.py,sha256=bDwCmdEK-WkgxQMFBiMuchv8Mm7C0-GZJ6usm-PQk14,4461
|
145
145
|
hdl/utils/vis_tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
146
|
-
hdl/utils/vis_tools/scene_detect.py,sha256=
|
146
|
+
hdl/utils/vis_tools/scene_detect.py,sha256=XM2oYEl7cnN4vTbxcX7rtzNXWe2ThvmwMXRKix6DMhY,6536
|
147
147
|
hdl/utils/weather/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
148
148
|
hdl/utils/weather/weather.py,sha256=k11o6wM15kF8b9NMlEfrg68ak-SfSYLN3nOOflFUv-I,4381
|
149
|
-
hjxdl-0.3.
|
150
|
-
hjxdl-0.3.
|
151
|
-
hjxdl-0.3.
|
152
|
-
hjxdl-0.3.
|
153
|
-
hjxdl-0.3.
|
149
|
+
hjxdl-0.3.50.dist-info/licenses/LICENSE,sha256=lkMiSbeZHBQLB9LJEkS9-L3Z-LBC4yGnKrzHSG8RkPM,2599
|
150
|
+
hjxdl-0.3.50.dist-info/METADATA,sha256=JhQSTVrCUDr65kahnurqyEuAYO4lEuLK9DAD1M7t94I,1332
|
151
|
+
hjxdl-0.3.50.dist-info/WHEEL,sha256=Nw36Djuh_5VDukK0H78QzOX-_FQEo6V37m3nkm96gtU,91
|
152
|
+
hjxdl-0.3.50.dist-info/top_level.txt,sha256=-kxwTM5JPhylp06z3zAVO3w6_h7wtBfBo2zgM6YZoTk,4
|
153
|
+
hjxdl-0.3.50.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|