Chain-based framework to split image processing into components.
cv2studio is an OpenCV framework that give
you an ability to decompose processing flow into
- Component-based development
- Channel independence
- Classes wrappers for HighGUI elements of OpenCV
- Channel independence for components
The main principle behind this framework is decomposition. Splitting up a code into one-format components make it highly reusable. It becomes easy to develop different parts of video/image processing separately and share it with others.
To install the latest release:
pip install cv2studio
Before using features of the framework goes importing.
from cv2studio import App, Component
To create a component describe a class derived from
To use this class it's required to declare the method
img is an image to be process. This function must return an image as well.
class Blur(Component): def process(self, img): img = cv2.GaussianBlur(img, (5, 5), 5) return img
This component apply blur to an input image.
To create an app that will hold processing components
describe a class derived from 'App' and add components
class VideoApp(App): def __init__(self, path): App.__init__(self, path, VIDEO) # self.add_component(MyComponent()) self.add_component(Blur())
To run the described app use
It will start main processing loop with applying
chain of added component.
app = VideoApp('path/to/video') app.main_loop()
main_loop starts a video processing loop. For creating
more complex app see the following examples.
To run tests run the following command:
We use SemVer for versioning. For the versions available, see the tags on this repository.
Please read CONTRIBUTE.md for details on our code of conduct, and the process for submitting pull requests to us.
This project is licensed under the MIT License - see the LICENSE.md file for details
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size cv2studio-1.0.2.tar.gz (6.8 kB)||File type Source||Python version None||Upload date||Hashes View|