Skip to content

gnastacast/dvrk-vtk-registration

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

90 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DaVinci

This project registers stl's to the daVinci robot using monocular vision. It is made to live in a catkin workspace using catkin build tools http://catkin-tools.readthedocs.io/en/latest/ but as it's all python it doesn't need to be built.

Compatibility

This project was tested using:

  • python 2.7.11 and 2.7.3
  • vtk 6.3.0 and 5.8.0
  • cv2 2.4.11 and 2.4.9
  • Qt 4.8.7 and 4.8.1
  • PyQt4 4.11.4 and 4.9.1

Code overview

The most important pieces of code are

  • tools/camCalibration.py
    • Running this will generate camera intrinsic and distortion matrices
  • tools/daVinciCalibration.py
    • Running this will use the camera data generated by the function above to register the robot to the camera
    • If no arguments are provided, camera parameters are pulled from the vtk_registration/src/defaults/ directory.
  • code/vtk_registration.py
    • Running this will use both of the files generated above and allows you to register an STL to the daVinci robot
    • If no arguments are provided, resources are pulled from the vtk_registration/src/defaults/ directory.

Model/View/Controller for vtk_registration.py

  • code/controller.py All of the processing is done using functions in this file.
  • code/model.py All of the data used by the QT application is stored in this class.
  • code/views/main_view.py Handles high level button presses and interaction
  • code/views/main_view.ui A qtDesigner file which is the only way you should edit the GUI
  • code/views/ui_main_view.py A file generated by qtDesigner that provides the bare skeleton for the UI.

Other helper function code

  • code/amoeba_annealer.py A general class for downhill simplex originally written by Thomas R. Metcalf and modified to add simulated annealing.
  • vtkTools.py A collection of functions for vtk that are used throughout the model, view, and controller.

Other files and folders

  • defaults/Logitech_c920 Camera data for logitech webcam including a spec sheet and an intrinsic matrix from OpenCV
  • defaults/objects various STL files to register
  • launch/test_dvrk_full.launch launch file for dVRK

Overall file structure

defaults/
├── Logitech_c920/
└── objects/
launch/
└── test_dvrk_full.launch - launch file for running dVRK
code/
├── amoeba_annealer.py
├── controller.py
├── model.py
├── views
│   ├── main_view.py 
│   ├── main_view.ui
│   └── ui_main_view.py
├── vtk_registration.py
└── vtkTools.py
tools/
├── camCalibration.py
└── daVinciCalibration.py
CMakeLists.txt
package.xml

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages