I have the basis:
>>> m = 6
>>> basis = np.zeros((m, m))
>>> np.fill_diagonal(basis, 1)
array([[1. 0. 0. 0. 0. 0.]
[0. 1. 0. 0. 0. 0.]
[0. 0. 1. 0. 0. 0.]
[0. 0. 0. 1. 0. 0.]
[0. 0. 0. 0. 1. 0.]
[0. 0. 0. 0. 0. 1.]]
How can I access the superposition of a vector? Let's say from:
vec = [0, 1, 1, 0, 1, 0]
So I want the output:
array([[0. 1. 0. 0. 0. 0.]
[0. 0. 1. 0. 0. 0.]
[0. 0. 0. 0. 1. 0.]]