Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when writing two-dimensional signal in mrcz format #73

Open
Tracked by #99
nem1234 opened this issue Dec 8, 2022 · 0 comments
Open
Tracked by #99

Error when writing two-dimensional signal in mrcz format #73

nem1234 opened this issue Dec 8, 2022 · 0 comments
Labels
type: bug Something isn't working

Comments

@nem1234
Copy link
Contributor

nem1234 commented Dec 8, 2022

Describe the bug

When writing 2-dimensional signal in mrcz format,
IndexError exception is raised in rsciio/mrcz/api.py.

>   pixelsize = [signal["axes"][I]["scale"] for I in _WRITE_ORDER]
E   IndexError: list index out of range

To Reproduce

Steps to reproduce the behavior:

from hyperspy.signals import Signal2D

s = Signal2D(np.arange(256, dtype=np.uint8).reshape(16,16))
s.save("test.mrcz")

Expected behavior

current mrcz/specifications.yaml shows
writes: [[2, 0], [2, 1], [2, 2], [3, 0]]
but it seems that only 3-dimensional data can be accepted.
writes should be [[3, 0]] ?

Python environement:

  • RosettaSciIO version: main/HEAD
  • Python version: 3.8
  • HyperSpy version: RELEASE_next_major/HEAD

Additional context

@nem1234 nem1234 added the type: bug Something isn't working label Dec 8, 2022
@jlaehne jlaehne added this to the v0.1.0 initial release milestone Jan 16, 2023
@jlaehne jlaehne mentioned this issue Apr 17, 2023
19 tasks
@ericpre ericpre removed this from the v0.1.0 initial release milestone Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants