systemsgenetics / granny Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v3.0
License: GNU General Public License v3.0
This should always print the version of granny.
This simply needs to be moved over to the new MVC framework
Convert ImageJ macro to Python
... that's it
When I accidentally provided a path that was not a directory I got the following error:
granny -i cli -d /local/projects/granny/demo/cross_section_images/cross_section_tray/cross_section_demo_image.jpeg -a segmentation
Traceback (most recent call last):
File "/home/ficklin/.local/bin/granny", line 8, in <module>
sys.exit(run())
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/GrannyBase.py", line 31, in run
GrannyCLI(parser).run()
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/Interfaces/UI/GrannyCLI.py", line 101, in run
images = self.listImages(self.image_dir)
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/Interfaces/UI/GrannyCLI.py", line 61, in listImages
image_files: List[str] = os.listdir(image_dir)
NotADirectoryError: [Errno 20] Not a directory: '/local/projects/granny/demo/cross_section_images/cross_section_tray/cross_section_demo_image.jpeg'
We need a more graceful error message to report to the user
We need updated user's documenation for v1.0 of Granny
We need a dockerized version of Granny to make it easy for folks to use Granny
This simply needs to be converted from the previous version of Granny over to the new MVC framework.
When running granny with the demo data we seem to be missing the model for segmentation and we get the following error:
Traceback (most recent call last):
File "/home/ficklin/.local/bin/granny", line 8, in <module>
sys.exit(run())
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/GrannyBase.py", line 31, in run
GrannyCLI(parser).run()
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/Interfaces/UI/GrannyCLI.py", line 110, in run
analysis = aclass(images)
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/Analyses/Segmentation.py", line 24, in __init__
self.AIModel.loadModel()
File "/home/ficklin/.local/lib/python3.10/site-packages/Granny/Models/AIModel/YoloModel.py", line 25, in loadModel
self.model = YOLO(self.model_dir)
File "/home/ficklin/.local/lib/python3.10/site-packages/ultralytics/engine/model.py", line 134, in __init__
self._load(model, task=task)
File "/home/ficklin/.local/lib/python3.10/site-packages/ultralytics/engine/model.py", line 215, in _load
self.model, self.ckpt = attempt_load_one_weight(weights)
File "/home/ficklin/.local/lib/python3.10/site-packages/ultralytics/nn/tasks.py", line 709, in attempt_load_one_weight
ckpt, weight = torch_safe_load(weight) # load ckpt
File "/home/ficklin/.local/lib/python3.10/site-packages/ultralytics/nn/tasks.py", line 634, in torch_safe_load
ckpt = torch.load(file, map_location="cpu")
File "/home/ficklin/.local/lib/python3.10/site-packages/torch/serialization.py", line 791, in load
with _open_file_like(f, 'rb') as opened_file:
File "/home/ficklin/.local/lib/python3.10/site-packages/torch/serialization.py", line 271, in _open_file_like
return _open_file(name_or_buffer, mode)
File "/home/ficklin/.local/lib/python3.10/site-packages/torch/serialization.py", line 252, in __init__
super().__init__(open(name, mode))
FileNotFoundError: [Errno 2] No such file or directory: '/home/ficklin/.local/lib/python3.10/site-packages/Granny/Analyses/config/Segmentation/granny_v1_yolo8.pt
Solution
We cannot package the model inside of the software. It's too big (~300MB). So, we need to put the model in a public repository so it can be downloaded. Perhaps that can be on the OSF (https://osf.io/). We should name the files in this way granny-v{granny_version}-{model_name}-v{model_version}.pt
. We should add a new argument to the segmentation step that indicates where the model is located. If a local path is provided then the local model file is used. If a string of the form {model_name}-v{model_version}
is provided, then Granny will download the model file from OSF, store it in the current directory and then use that model.
Currently Granny gives the error if no arguments are provided
Error: unknown interface
By default it is supposed to use 'cli' as the default interface if none is provided
We need to complete the design for the metadata classes to make sure they meet expecatations for v1.0
For linking analysis in a worklfow we need to have the input directory and the output directory specified in an analysis. But also, let's rename them to the be --input_dir
and --output_dir
. Anything needed for an analysis must be in that directory.
This simply needs conversion over to the new MVC framework.
Hard-code the color rating color values in the analysis so the card doesn't need to be read in for the analysis to work. Also, add the color card image to the docs folder so we can refer to it in the documentation.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.