spatialmath-python icon indicating copy to clipboard operation
spatialmath-python copied to clipboard

SE2.norm() seems broken

Open ilmagico opened this issue 2 years ago • 1 comments

It seems that SE2.norm tries to call some trnorm2 function which is not defined. Here's how to reproduce, after cloning a fresh copy of this repo and pip install . in a virtualenv:

Python 3.10.2 (main, Jan 15 2022, 19:56:27) [GCC 11.1.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import spatialmath as sm
>>> sm.SE2().norm()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/dtamino/oss/spatialmath-python/spatialmath/baseposematrix.py", line 541, in norm
    return self.__class__([base.trnorm2(x) for x in self.data])
  File "/home/dtamino/oss/spatialmath-python/spatialmath/baseposematrix.py", line 541, in <listcomp>
    return self.__class__([base.trnorm2(x) for x in self.data])
AttributeError: module 'spatialmath.base' has no attribute 'trnorm2'. Did you mean: 'trnorm'?

ilmagico avatar Jun 07 '22 01:06 ilmagico

trnorm2 never got written... It's on the list now.

petercorke avatar Jun 12 '22 01:06 petercorke

PR merged (https://github.com/bdaiinstitute/spatialmath-python/pull/89)

myeatman-bdai avatar Nov 14 '23 15:11 myeatman-bdai