Skip to content
Snippets Groups Projects
Commit d2a07ec8 authored by fima's avatar fima :beers:
Browse files

Merge branch 'change_GUI_launch_pipeline' into 'main'

Change gui launch pipeline

See merge request !51
parents caede17f 8ef7e066
Branches
Tags
1 merge request!51Change gui launch pipeline
......@@ -6,4 +6,3 @@ import qim3d.models as models
import logging
examples = io.ImgExamples()
downloader = io.Downloader()
......@@ -71,7 +71,7 @@ class Interface:
session.zpos = zpos
return session
def launch(self, img=None):
def launch(self, img=None,**kwargs):
# Show header
if self.show_header:
internal_tools.gradio_header(self.title, self.port)
......@@ -90,6 +90,7 @@ class Interface:
quiet=quiet,
height=self.height,
width=self.width,
**kwargs
)
return
......
......@@ -22,7 +22,7 @@ class Downloader:
[folder_name_n] (str): folder class with the name of the n-th folder in the QIM data repository.
Example:
dl = Downloader()
dl = qim3d.io.Downloader()
# Downloads and Loads (optional) image:
img = dl.Corals.Coral2_DOWNSAMPLED(load = True)
"""
......
......@@ -13,23 +13,39 @@ def main():
gui_parser.add_argument('--annotation-tool', action='store_true', help='Run annotation tool.')
gui_parser.add_argument('--local-thickness', action='store_true', help='Run local thickness tool.')
gui_parser.add_argument('--host', default='0.0.0.0', help='Desired host.')
gui_parser.add_argument('--platform', action='store_true', help='Use QIM platform address')
args = parser.parse_args()
if args.subcommand == 'gui':
arghost = args.host
if args.data_explorer:
if args.platform:
data_explorer.run_interface(arghost)
else:
interface = data_explorer.Interface()
interface.launch()
elif args.iso3d:
if args.platform:
iso3d.run_interface(arghost)
else:
interface = iso3d.Interface()
interface.launch()
elif args.annotation_tool:
if args.platform:
annotation_tool.run_interface(arghost)
else:
interface = annotation_tool.Interface()
interface.launch()
elif args.local_thickness:
if args.platform:
local_thickness.run_interface(arghost)
else:
interface = local_thickness.Interface()
interface.launch()
if __name__ == '__main__':
main()
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment