1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

Merge branch 4.x

This commit is contained in:
Alexander Smorkalov
2023-06-01 09:37:38 +03:00
565 changed files with 84396 additions and 17589 deletions
@@ -44,7 +44,7 @@ from matplotlib import pyplot as plt
imgL = cv.imread('tsukuba_l.png', cv.IMREAD_GRAYSCALE)
imgR = cv.imread('tsukuba_r.png', cv.IMREAD_GRAYSCALE)
stereo = cv.StereoBM_create(numDisparities=16, blockSize=15)
stereo = cv.StereoBM.create(numDisparities=16, blockSize=15)
disparity = stereo.compute(imgL,imgR)
plt.imshow(disparity,'gray')
plt.show()
@@ -63,6 +63,9 @@ There are some parameters when you get familiar with StereoBM, and you may need
- uniqueness_ratio: Another post-filtering step. If the best matching disparity is not sufficiently better than every other disparity in the search range, the pixel is filtered out. You can try tweaking this if texture_threshold and the speckle filtering are still letting through spurious matches.
- prefilter_size and prefilter_cap: The pre-filtering phase, which normalizes image brightness and enhances texture in preparation for block matching. Normally you should not need to adjust these.
These parameters are set with dedicated setters and getters after the algoritm
initialization, such as `setTextureThreshold`, `setSpeckleRange`, `setUniquenessRatio`,
and more. See cv::StereoBM documentation for details.
Additional Resources
--------------------
@@ -30,7 +30,7 @@ programmer to express ideas in fewer lines of code without reducing readability.
Compared to languages like C/C++, Python is slower. That said, Python can be easily extended with
C/C++, which allows us to write computationally intensive code in C/C++ and create Python wrappers
that can be used as Python modules. This gives us two advantages: first, the code is as fast as the
original C/C++ code (since it is the actual C++ code working in background) and second, it easier to
original C/C++ code (since it is the actual C++ code working in background) and second, it is easier to
code in Python than C/C++. OpenCV-Python is a Python wrapper for the original OpenCV C++
implementation.
@@ -79,8 +79,9 @@ Below is the list of contributors who submitted tutorials to OpenCV-Python.
Additional Resources
--------------------
-# A Quick guide to Python - [A Byte of Python](http://swaroopch.com/notes/python/)
2. [NumPy Quickstart tutorial](https://numpy.org/devdocs/user/quickstart.html)
3. [NumPy Reference](https://numpy.org/devdocs/reference/index.html#reference)
4. [OpenCV Documentation](http://docs.opencv.org/)
-# A Quick guide to Python - [A Byte of Python](https://python.swaroopch.com/)
1. [A Quick guide to Python](https://www.freecodecamp.org/news/the-python-guide-for-beginners/)
2. [NumPy Quickstart tutorial](https://numpy.org/doc/stable/user/quickstart.html)
3. [NumPy Reference](https://numpy.org/doc/stable/reference/index.html)
4. [OpenCV Documentation](https://docs.opencv.org/)
5. [OpenCV Forum](https://forum.opencv.org/)
@@ -33,6 +33,8 @@ Installing OpenCV from prebuilt binaries
-# Copy **cv2.pyd** to **C:/Python27/lib/site-packages**.
-# Copy the **opencv_world.dll** file to **C:/Python27/lib/site-packages**
-# Open Python IDLE and type following codes in Python terminal.
@code
>>> import cv2 as cv