a framework that wraps opencv for our needs in FRC
Spikes ComputerVision Framework
Spikes ComputerVision Framework, or scvf for short, is a framework that is made to make programming CV for the FRC easier
$ python3 -m pip install scvf
communication through network tables
pipeline_name key to send the pipeline_name
camera_id key to send the camera id
exposure key to send the exposure for the camera
Though we recommend grip as the main tool to generate cv2 pipelines
using grip is not strictly required
You can provide any object to server as a pipeline as long as it contains the next two methods:
process() - a method that processes a given image
get_output() - a method that returns the output of the processing
scvf receives two functions that are responsible for communications with external data sources.
settings_supplier(callback)this function receives settings and supplies them to callback provided to it.
output_consumer(output)this function sends the output of the image processing to it's next destination
GRIP and SCVF compatibility
if you are using grip to generate your pipelines keep in mind that the pipelines generated from it aren't compatible with scvf out of the box due to differences between python3 and python2
as of now, these changes are required:
- change the enum for the blur type to a python3-enum
- change the findContours function as instructed here
- add a
get_output()method that is compatible with the API specified above
- Switch between the
contoursvariables in the
filter_contoursfunction of your pipeline
- make sure that your custom
output_consumeris compatible with the output provided by your pipelines.
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.