Fix normalize_along_axis

This commit is contained in:
Grant Sanderson
2022-12-22 11:52:55 -07:00
parent 5af4b9cc65
commit a4d47f64b0

View File

@ -178,8 +178,7 @@ def normalize_along_axis(
norms = np.sqrt((array * array).sum(axis))
norms[norms == 0] = 1
buffed_norms = np.repeat(norms, array.shape[axis]).reshape(array.shape)
array /= buffed_norms
return array
return array / buffed_norms
def get_unit_normal(