py_pol.stokes.Stokes.__repr__ raises error if py_pol.stokes.Stokes.M has multiple columns
Issue #6
resolved
This is a minimum working example:
# Create a Stokes object with two columns.
S = py_pol.stokes.Stokes('S')
S.from_matrix(np.matrix([[1, 1, 0, 0], [1, 0, 1, 0]]).T)
# Note that plotting is supported,
ax, fig = py_pol.drawings.draw_poincare_sphere(
stokes_points=S,
kind='scatter',
color='r')
# but printing raises a TypeError
print(S)
# TypeError: unsupported format string passed to numpy.ndarray.__format__
OS: Windows 10
Version
py_pol.__version__
'0.2.3'
Comments (4)
-
-
reporter Dear Jesu,
Thank you for the fast reply. I’ll keep watching the new releases.
Best, Leon
-
Dear Leon.
The new version of py_pol has been released. You can try to use it now.
-
- changed status to resolved
- Log in to comment
Currently, py_pol is not designed to contain several vectors/matrices in the same object. However, we are currently developing a ¡n upgrade to the module so it can work with multiple elements in the same objects. We will upload an alpha version with this functionality.