seequent / properties

An organizational aid and wrapper for validation and tab completion of class properties/traits.
http://propertiespy.rtfd.org
MIT License
18 stars 9 forks source link

Vector3 + numpy #197

Open lheagy opened 7 years ago

lheagy commented 7 years ago

There are a couple non-intuitive things that can happen when performing operations on a vector3 with a numpy array. In the below screen-shot, there is an example using np.kron and showing that it is not commutative with the type that is returned depending on the order of inputs:np.kron(vector3, numpy) returns an (invalid) vector3, while np.kron(numpy, vector3) returns a numpy array. Ideally, the behaviour should be the latter, returning a numpy array (or a Vector3Array, but that might be getting to fancy).

image

fwkoch commented 7 years ago

@lheagy Thanks for this - I'm glad you are putting the vectormath properties through their paces. I've created a related issue here that should hopefully solve this: https://github.com/aranzgeo/vectormath/issues/26