aboutsummaryrefslogtreecommitdiff
path: root/gui.py
diff options
context:
space:
mode:
Diffstat (limited to 'gui.py')
-rw-r--r--gui.py25
1 files changed, 16 insertions, 9 deletions
diff --git a/gui.py b/gui.py
index 8f2ad4c..f99b62a 100644
--- a/gui.py
+++ b/gui.py
@@ -19,6 +19,8 @@ class GuiMain(object):
self.__predict_images_top = StringVar(self.__master, value=str(args["predict_images_top"]))
self.__predict_images_skip_detail = BooleanVar(self.__master, value=args["predict_images_skip_detail"])
self.__predict_images_detail_factor = StringVar(self.__master, value=str(args["predict_images_detail_factor"]))
+ self.__predict_videos = BooleanVar(self.__master, value=args["predict_videos"])
+ self.__predict_videos_key_frames = StringVar(self.__master, value=str(args["predict_videos_key_frames"]))
self.__gui_tag = BooleanVar(self.__master, value=args["gui_tag"])
self.__gui_image_length = StringVar(self.__master, value=str(args["gui_image_length"]))
self.__open_system = BooleanVar(self.__master, value=args["open_system"])
@@ -43,15 +45,18 @@ class GuiMain(object):
Checkbutton(self.__master, text="Skip detail scan in image prediction", variable=self.__predict_images_skip_detail).grid(row=6, column=0, columnspan=4, sticky=W)
Label(self.__master, text="Width factor for detail scan:").grid(row=7, column=0)
Entry(self.__master, textvariable=self.__predict_images_detail_factor, validate='all', validatecommand=(validate_number, '%P')).grid(row=7, column=1, columnspan=1)
- Checkbutton(self.__master, text="Show GUI for tagging", variable=self.__gui_tag).grid(row=8, column=0, columnspan=4, sticky=W)
- Label(self.__master, text="Image GUI preview size:").grid(row=9, column=0)
- Entry(self.__master, textvariable=self.__gui_image_length, validate='all', validatecommand=(validate_number, '%P')).grid(row=9, column=1, columnspan=1)
- Checkbutton(self.__master, text="Open all files with system default", variable=self.__open_system).grid(row=10, column=0, columnspan=4, sticky=W)
- Checkbutton(self.__master, text="Skip prompt for file tags", variable=self.__skip_prompt).grid(row=11, column=0, columnspan=4, sticky=W)
- Checkbutton(self.__master, text="Skip already tagged files", variable=self.__skip_tagged).grid(row=12, column=0, columnspan=4, sticky=W)
- Label(self.__master, text="Start at index:").grid(row=13, column=0)
- Entry(self.__master, textvariable=self.__index, validate='all', validatecommand=(validate_number, '%P')).grid(row=13, column=1, columnspan=1)
- Button(self.__master, text="Start", command=self.__master.destroy).grid(row=14, column=0, columnspan=4)
+ Checkbutton(self.__master, text="Use prediction for video tagging", variable=self.__predict_videos).grid(row=8, column=0, columnspan=4, sticky=W)
+ Label(self.__master, text="Number of key frames:").grid(row=9, column=0)
+ Entry(self.__master, textvariable=self.__predict_videos_key_frames, validate='all', validatecommand=(validate_number, '%P')).grid(row=9, column=1, columnspan=1)
+ Checkbutton(self.__master, text="Show GUI for tagging", variable=self.__gui_tag).grid(row=10, column=0, columnspan=4, sticky=W)
+ Label(self.__master, text="Image GUI preview size:").grid(row=11, column=0)
+ Entry(self.__master, textvariable=self.__gui_image_length, validate='all', validatecommand=(validate_number, '%P')).grid(row=11, column=1, columnspan=1)
+ Checkbutton(self.__master, text="Open all files with system default", variable=self.__open_system).grid(row=12, column=0, columnspan=4, sticky=W)
+ Checkbutton(self.__master, text="Skip prompt for file tags", variable=self.__skip_prompt).grid(row=13, column=0, columnspan=4, sticky=W)
+ Checkbutton(self.__master, text="Skip already tagged files", variable=self.__skip_tagged).grid(row=14, column=0, columnspan=4, sticky=W)
+ Label(self.__master, text="Start at index:").grid(row=15, column=0)
+ Entry(self.__master, textvariable=self.__index, validate='all', validatecommand=(validate_number, '%P')).grid(row=15, column=1, columnspan=1)
+ Button(self.__master, text="Start", command=self.__master.destroy).grid(row=16, column=0, columnspan=4)
def loop(self):
self.__master.mainloop()
@@ -64,6 +69,8 @@ class GuiMain(object):
self.__args["predict_images_top"] = int(self.__predict_images_top.get())
self.__args["predict_images_skip_detail"] = self.__predict_images_skip_detail.get()
self.__args["predict_images_detail_factor"] = int(self.__predict_images_detail_factor.get())
+ self.__args["predict_videos"] = self.__predict_videos.get()
+ self.__args["predict_videos_key_frames"] = int(self.__predict_videos_key_frames.get())
self.__args["gui_tag"] = self.__gui_tag.get()
self.__args["gui_image_length"] = int(self.__gui_image_length.get())
self.__args["open_system"] = self.__open_system.get()