Skip to content

Commit

Permalink
Traffic light detection fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
Glas42 committed Jun 25, 2024
1 parent 788e35b commit f9678f7
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
4 changes: 4 additions & 0 deletions blog/V1.11.Minor.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ title: Version 1.11 > Minor
!!!
This changelog will contain all changes from 1.11.0 onwards before the next major version.
!!!

==- Version 1.11.47
Traffic light detection fix.
[!badge variant="dark" text="Glas42"] [!badge variant="ghost" text="TrafficLightDetection"]
==- Version 1.11.46
Try to fix mainUI root error on startup.
[!badge variant="dark" text="Tumppi066"] [!badge variant="ghost" text="MainUI"]
Expand Down
2 changes: 1 addition & 1 deletion changelog.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Try to fix mainUI root error on startup.
Traffic light detection fix.
4 changes: 2 additions & 2 deletions plugins/TrafficLightDetection/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -643,8 +643,6 @@ def GetAIModelProperties():
global MODEL_TRAINING_DATE
try:
ModelFolderExists()
if GetAIModelName() == "UNKNOWN":
return
MODEL_METADATA = {"data": []}
IMG_WIDTH = "UNKNOWN"
IMG_HEIGHT = "UNKNOWN"
Expand All @@ -654,6 +652,8 @@ def GetAIModelProperties():
MODEL_IMAGE_COUNT = "UNKNOWN"
MODEL_TRAINING_TIME = "UNKNOWN"
MODEL_TRAINING_DATE = "UNKNOWN"
if GetAIModelName() == "UNKNOWN":
return
torch.jit.load(os.path.join(f"{variables.PATH}plugins/TrafficLightDetection/AIModel", GetAIModelName()), _extra_files=MODEL_METADATA, map_location=AIDevice)
MODEL_METADATA = str(MODEL_METADATA["data"]).replace('b"(', '').replace(')"', '').replace("'", "").split(", ")
for var in MODEL_METADATA:
Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.11.46
1.11.47

0 comments on commit f9678f7

Please sign in to comment.