A Macro in Dragonfly to prune automatically annotated astrocyte volumes
The following instructions will allow you to install this macro across any new computer.
-
Press [Windows Key] + [R] and search "AppData"
-
Search for "Local" folder
-
Search for "ORS" folder
-
Search for "DragonflyXXXX.X" folder
-
Search for "pythonUserExtensions" folder
-
Search for "Macros" folder
-
Place the 3 macros downloaded from this github into this folder.
-
KEEP THIS FOLDER OPEN WHILE YOU DO STEPS 9 - 17
-
Open Dragonfly Program
-
Navigate to the "Utilities" tab
-
On the drop down, click "Start Command Prompt"
-
In the Command Prompt, type "pip install opencv-python"
-
Close and reopen dragonfly once the python package has been installed
-
Navigate to the "Artificial Intelligence" tab
-
On the drop down, click "Deep Learning Tool"
-
Right click your model of interest, and select "Open Model Folder in File Browser"
-
At the top of your file browser, click the "models" folder that comes right before the specific network model folder you are in. You should have navigated from this: C:\ProgramData\ORS\DragonflyXXXX.X\pythonAllUsersExtensions\PythonPluginExtensions\DeepTrainer\models\SpecificNetworkModel_XXXXXXXXXXXXXXXXXXXXX to this: C:\ProgramData\ORS\DragonflyXXXX.X\pythonAllUsersExtensions\PythonPluginExtensions\DeepTrainer\models
-
Once you are in the model folder, identify your astrocyte model folder.
-
Right click the astrocyte model folder, and click "Rename"
-
DO NOT CHANGE THE NAME OF THE FOLDER, copy and paste the name of the folder into a seperate text file. (e.g. ExampleModelFolder_73dae9de648c11eb93d300d8615a0557)
-
Repeat steps 14-16 for your mitochondria model folder.
-
RETURN TO "AppData/Local/Ors/Dragonfly/pythonUserExtensions/Macros" FROM STEP 8
-
Open "SegmentAstrocytefromVolumev2_XXXXXXXX.py" with a text editor (notepad is fine)
-
Navigate to line 68
- Paste only the UID of the astrocyte folder and mitochondria folder into the quotation marks
- Save the python file
- Open dragonfly and test macro!