In this recipe, you will learn how to solve systems of linear equations using OpenCV. This functionality is a key building block of many computer vision and machine learning algorithms.
Solving systems of linear equations (including under- and over-determined)
Getting ready
Before you proceed with this recipe, you need to install the OpenCV 3.3 (or greater) Python API package.
How to do it...
You need to complete the following steps:
- Import the modules:
import cv2
import numpy as np
- Generate a system of linear equations:
N = 10
A = np.random.randn(N,N)
while np.linalg...