Skip to content

AdaptiveMotorControlLab/MouseArm-3D-tooling

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A simple calibration and lifting pipeline based on OpenCV 🏋️

First, get the data and untar it. Your data dir should look like this:

❯ find data -type f
data/2018_mouse_reaching_rig5/calibration/CAL_side15.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side14.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side5.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side1.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side0.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side3.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front14.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front5.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front3.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side4.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side16.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front15.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front10.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front0.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front1.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front16.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_front4.jpg
data/2018_mouse_reaching_rig5/calibration/CAL_side10.jpg
data/2018_mouse_reaching_rig5/README.md
data/2018_mouse_reaching_rig5/dlc/rigVideo_mouse-HoneyBee_day-77_attempt-1_camera-2_part-0_doe-20180803_rig-5DLC_resnet50_MackenzieJan21shuffle1_700000.h5
data/2018_mouse_reaching_rig5/dlc/honeybee_77.npz
data/2018_mouse_reaching_rig5/dlc/rigVideo_mouse-HoneyBee_day-77_attempt-1_camera-1_part-0_doe-20180803_rig-5DLC_resnet50_MackenzieJan21shuffle1_700000.h5

Build a container and launch the interactive shell:

./interact.sh continuumio/miniconda3 build

Within the shell, check if the code runs fine:

python -m pytest test

This should complete without errors.

Perfect! You can now start running the demo:

./calibration.sh

Have a look at lifting.calibrate.__main__ for details how to use the code, exporting camera matrices etc. You can also launch an interactive viewer of the result using

voila README.ipynb

which will launch a web viewer at http://localhost:8866/. Alternatively, you can also open the file in a jupyter notebook server.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors