Skip to content

numpy v1.24.0 breaks reader IBW #266

@jotelha

Description

@jotelha

With numpy 1.24.0, I get

Traceback (most recent call last):
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/.snakemake/scripts/tmp3d17vir4.build_feature_matrix.py", line 10, in <module>
    import SurfaceTopography as ST
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/SurfaceTopography/__init__.py", line 31, in <module>
    from .Container import SurfaceContainer, read_container, read_published_container  # noqa: F401
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/SurfaceTopography/Container/__init__.py", line 27, in <module>
    from .IO import read_container, read_published_container  # noqa: F401
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/SurfaceTopography/Container/IO.py", line 43, in <module>
    from ..IO import open_topography
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/SurfaceTopography/IO/__init__.py", line 41, in <module>
    from .IBW import IBWReader
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/SurfaceTopography/IO/IBW.py", line 29, in <module>
    from igor.binarywave import load as loadibw
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/igor/binarywave.py", line 110, in <module>
    1:_numpy.complex, # NT_CMPLX, makes number complex.
  File "/mnt/dat2/git/ContactEngineering/SurfaceTopographyML-floor-tile/venv/lib/python3.8/site-packages/numpy/__init__.py", line 284, in __getattr__
    raise AttributeError("module {!r} has no attribute "
AttributeError: module 'numpy' has no attribute 'complex'

due to this line https://github.com/wking/igor/blob/41952c5fa352fdbe95557a759cdc057fe3ee74f9/igor/binarywave.py#L110 in the igor/binarywave dependency. This does not happen with numpy v 1.23.5.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions