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

Merge branch 'GUI-fix' into 'main'

Small fix in GUI

See merge request !111
parents c27454e7 99ba3e55
No related branches found
No related tags found
1 merge request!111Small fix in GUI
from pathlib import Path
from abc import abstractmethod, ABC
from os import path
from os import path, listdir
import gradio as gr
......@@ -113,13 +113,7 @@ class InterfaceWithExamples(BaseInterface):
self._set_examples_list()
def _set_examples_list(self):
examples = [
"fly_150x256x256.tif",
"cement_128x128x128.tif",
"NT_128x128x128.tif",
"shell_225x128x128.tif",
"bone_128x128x128.tif",
]
self.img_examples = []
for example in examples:
self.img_examples.append([path.join(self.qim_dir, "examples", example)])
valid_sufixes = (".tif", ".tiff", ".h5", ".nii", ".gz", ".dcm", ".DCM", ".vol", ".vgi", ".txrm", ".txm", ".xrm")
examples_folder = path.join(self.qim_dir, 'examples')
self.img_examples = [path.join(examples_folder, example) for example in listdir(examples_folder) if example.endswith(valid_sufixes)]
......@@ -85,7 +85,7 @@ class Interface(InterfaceWithExamples):
def define_interface(self):
gr.Markdown(
"Interface for _Fast local thickness in 3D and 2D_ (https://github.com/vedranaa/local-thickness)"
"Interface for _Fast local thickness in 3D_ (https://github.com/vedranaa/local-thickness)"
)
with gr.Row():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment