Giter Club home page Giter Club logo

scikit-surgerybard's Introduction

Basic Augmented Reality Demo.

Logo

Travis CI test status

Test coverage

Documentation Status

SciKit-SurgeryBARD Demonstration on YouTube

The SciKit-Surgery paper

Follow scikit_surgery on twitter

Author(s): Miguel Xochicale, Thomas Dowrick, Stephen Thompson and Matt Clarkson; Contributor(s): Mian Ahmad.

Basic Augmented Reality Demo (BARD) is part of the SciKit-Surgery software project, developed at the Wellcome EPSRC Centre for Interventional and Surgical Sciences, part of University College London (UCL).

The BARD is tested on Python 3.8. and may support other Python versions.

Developing

Encountering Problems?

Please get in touch or raise an issue.

Contributing

Please see the contributing guidelines.

Copyright 2019 University College London. Basic Augmented Reality Demo. is released under the BSD-3 license. Please see the license file for details.

Acknowledgements

Supported by Wellcome and EPSRC.

scikit-surgerybard's People

Contributors

drmianasbat avatar enkaoua avatar mattclarkson avatar mianasbat avatar mxochicale avatar tdowrick avatar thompson318 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

scikit-surgerybard's Issues

Fix and tidy up bardCameraCalibration

In GitLab by @StephenThompson on Jun 19, 2019, 16:26

Essential: return -s command line option. It looks to me like the object points have a 1 mm spacing. Which is going to give us bad calibration in most cases.

Nice: It would be nice to have some verbose out put, and some writing out out of annotated images, so we can have a discussion of what's going on.

Pointer tracking

In GitLab by @StephenThompson on Jul 4, 2019, 15:30

Mac Mojave 10.14.5 macbook pro.
One of our students had one of these. The tracked pointer markers (spheres) do not overlay with the visible image. I do not understand how this could be.

Command line OR GUI app to grab video images

In GitLab by @MattClarkson on Mar 21, 2019, 14:05

Using opencv-python, this should be a case of implementing a fairly standard grabber.

  • See basic functionality in the main BARD user instructions.
  • Example python functionality is here. The original C++ code is split over more files, and relies on OpenCV and key bindings. Its probably easier to write a pure python grabber, like I linked to.

Less than 1 days work (hopefully).

Update documentation

In GitLab by @MattClarkson on Mar 21, 2019, 14:14

In line with current standards... probably best to update the Word doc instructions to Sphinx docs.

  • Original BARD instructions are here
  • Re-write the manual, testing each bit of code as you go.

Assemble the main bard app to run live overlay

In GitLab by @MattClarkson on Mar 21, 2019, 14:12

This will require a bit of coordination amoungst all SNAPPY libraries

  • Load config from .json file using scikit-surgerycore ConfigurationManager, like SmartLiver does.
  • Load VTK models using scikit-surgeryvtk SurfaceModel, like SmartLiver
  • Load camera calibration data using standard numpy functions, (use command line parameter, load text file).
  • Read Video from webcam using standard opencv-python (from Tom's base class)
  • Use overlay widget from scikit-surgeryvtk (from Tom's base class)
  • You'll need a GUI program. Look at scikit-surgeryutils for examples.

Then ASK about:

  • Save standard models of Aruco tags, and just pre-load them at startup
  • Update transformations using scikit-surgerycore TransformationManager
  • Load any necessary fiducial points, using standard numpy functions, at startup
  • In the main program loop: extract aruco points, compute registrations, update position of tools, compute position of overlay, render.

About 3 to 4 days work I guess, if all the other bits are done in other libraries.

Resolve "Tidy ups with Matt" - [merged]

In GitLab by @mianahmad on May 1, 2019, 15:11

Merges 6-tidy-ups-with-Matt -> master

@MattClarkson
It would be convenient for me if you merge this branch and then I write the preliminary documentation for usage. During this update entry points are changed and default values are provided.

Command line app to do camera calibration

In GitLab by @MattClarkson on Mar 21, 2019, 13:48

Write simple demo app to do video camera calibration

  • See this example in C++, here
  • Create command line app bard_camera_calibration.py in top level folder
  • Create sksurgerybard/ui/bard_camera_calibration_command_line.py
  • Create sksurgerybard/ui/bard_camera_calibration_command_app.py
  • Use existing app as examples on how to run a command line app, i.e. see code in sksurgerybard commmand line app.
  • Add correct line to setup.py
  • Convert above mentioned C++ to Python, putting most code in bard_camera_calibration_command_app.py

Hopefully, now you are up to speed, about 1 or 2 days work.

@StephenThompson is familiar with all this, so can provide guidance.

Tidy up output of BARD pivot calibration

In GitLab by @StephenThompson on Jun 19, 2019, 17:18

At the moment it outputs 7 number without explanation of what they are. It would be more friendly to say what they are and to output a point_tip.txt which can then be put straight into bard.
Could we bring in in matplotlib to visualise point spread?

bard support for command line args?

In GitLab by @StephenThompson on Jun 19, 2019, 17:07

How are we going to support things like this ?
bard -w ~/build/BARD/Data/ref.txt -i ~/build/BARD/Data/intrinsics.txt -x 1280 -y 720
I'm inclined to just use config files?
Also need to update the app so that the above will run OK.

Make pivot calib unit test actually test the result.

In GitLab by @MattClarkson on Apr 30, 2019, 16:11

  • Fix output directory name to be not hard coded
  • run_demo should return pivot point
  • unit test should assert the right value
  • add scikit-surgerycore as dependency in requirements.txt and rebuild .tox folder.
  • remove pivot calibration code duplication

Dump tip positions

In GitLab by @StephenThompson on Jun 19, 2019, 17:19

bard -w ~/build/BARD/Data/ref.txt -i ~/build/BARD/Data/intrinsics.txt -x 1280 -y 720 -p ~/build/BARD/Data/pointer.txt -t -d ~/BARD

should output tip positions so we can do proscrustes. It would be nice if we had some user interface to make grabbing the points easier.

opencv-python removed because opencv-contrib-python is enough - [merged]

In GitLab by @mianahmad on Jul 3, 2019, 10:26

Merges 25-modulenotfound-cv2_aruco -> master

Closes #25

I think its better to merge the branch because I believe long time ago you mentioned that opencv-python and opencv-contrib-python have overlapping packages.

I noticed that modulenotfound cv2.aruco goes away if we get rid of opencv-python and keep opencv-contrib-python

Main app resizing

In GitLab by @StephenThompson on Jun 19, 2019, 09:27

When I start the main overlay app, the overlay is wrong until I manually resize the window. Once I've done that everything lines up nicely.

Command line app to do Pivot Calibration

In GitLab by @MattClarkson on Mar 21, 2019, 13:54

Most pivot calibration code (maths etc) is in scikit-surgerycore. This task is to create a command line app, so we can run it from this project.

Write simple command line app to do pivot calibration.

  • See this file for the entry point
  • See this file for the maths in C++, which you are now familiar with.
  • Create command line app bard_pivot_calibration.py in top level folder
  • Create sksurgerybard/ui/bard_pivot_calibration_command_line.py
  • Create sksurgerybard/ui/bard_pivot_calibration_command_app.py
  • Use existing app as examples on how to run a command line app, i.e. see code in sksurgerybard commmand line app.
  • Add correct line to setup.py
  • Convert above mentioned C++ to Python, putting most code in bard_pivot_calibration_command_app.py

Hopefully, now you are up to speed, less than 1 days work.

@StephenThompson is familiar with all this, so can provide guidance.

Tidy ups with Matt

In GitLab by @MattClarkson on Apr 30, 2019, 16:06

  • Rename top level python scripts, shorter names.
  • Rename name in setup.py
  • Update setup.py - "scikit-surgerybard is a Basic Augmented Reality Demo (BARD) based on scikit-surgery (SNAPPY).
  • Update setup.py URL to BARD URL
  • Update setup.py install_requires should match requirements.txt
  • Update README.rst
  • Go through all command line apps. Check for description strings, and default values.
  • Swap all print statements for six.print_
  • In camera calib - decide if you want windows, and make code consistent.

Fix mirroring

In GitLab by @StephenThompson on Jul 3, 2019, 22:41

There's some sort of mirroring going on. To get the fiducial registration working I had to flip the CT model and fiducuals around the xy plane.

Resolve "bardCameraCalibration also needs to get input via a json file" - [merged]

In GitLab by @mianahmad on Jul 8, 2019, 14:23

Merges 26-bardCameraCalibration-input-via-json -> master

Closes #26

This branch modifies calibration process so that it takes input via a configuration file.
The following command (1) will be replaced by command (2) to do the calibration.

(1)
python bardCameraCalibration.py  --xcorners 14 --ycorners 10 --size 24 -i <output_dir> --verbose

(2)
python3 bardCameraCalibration.py --config config/calibration_input.json

I also updated the respective test cases and documentation related to the above change.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.