Answers for "how to normalize a matrix in pyton"

2

numpy normalize matrix

import numpy as np
x= np.random.random((3,3))
print("Original Array:")
print(x)
xmax, xmin = x.max(), x.min()
x = (x - xmin)/(xmax - xmin)
print("After normalization:")
print(x)
Posted by: Guest on February-12-2021

Code answers related to "how to normalize a matrix in pyton"

Python Answers by Framework

Browse Popular Code Answers by Language