Merge pull request 'fixed bug in combination with the program.json.' (#8) from First_Starting_Bug into main

Reviewed-on: http://192.168.178.135:3000/Fabelous/MPENN/pulls/8
This commit is contained in:
Falko Victor Habel 2024-03-10 16:05:13 +00:00
commit 1828fb6b04
2 changed files with 21 additions and 20 deletions

11
main.py
View File

@ -5,8 +5,8 @@ import scripts.get_sys_info as system_code
from scripts.ClosePopup import ClosePopup
from scripts.settings import Settings
from scripts.converter import Converter
from scripts.labeling import Labeling
from scripts.Converter import Converter
from scripts.Labeling import Labeling
from scripts.folder_mangement.OpenFolder import OpenFolder
from scripts.folder_mangement.CreateFolder import CreateFolder
@ -257,6 +257,7 @@ class App(Ctk.CTk):
relwidth=0.6,
relheight=0.095
)
app = App()
app.mainloop()
if __name__ == '__main__':
app = App()
app.mainloop()

View File

@ -42,21 +42,21 @@ def load_json_file():
}
with open(json_file_path, 'w') as f:
json.dump(data, f, indent=2)
else:
# Load the file
with open(json_file_path, 'r') as f:
data = json.load(f)
window_width = data["window_width"]
window_height = data["window_height"]
window_state = data["window_state"]
btn_img_size = data["btn_img_size"]
skipable_frames = data["skipable_frames"]
img_format = data["img_format"]
used_threads = data["used_threads"]
thread_detection_mode = data["thread_detection_method"]
data_mode = data["data_mode"]
color = data["color"]
thickness = data["thickness"]
# Load the file
with open(json_file_path, 'r') as f:
data = json.load(f)
window_width = data["window_width"]
window_height = data["window_height"]
window_state = data["window_state"]
btn_img_size = data["btn_img_size"]
skipable_frames = data["skipable_frames"]
img_format = data["img_format"]
used_threads = data["used_threads"]
thread_detection_mode = data["thread_detection_method"]
data_mode = data["data_mode"]
color = data["color"]
thickness = data["thickness"]
thread_options = set_thread_options()
def calculate_automatic_threads():