Skip to content

Unpacking error: error('unpack requires a buffer of 4 bytes',) #23

@JianYugen

Description

@JianYugen

Hi. I've met an issue recently when using OOMMFDecode to convert .ovf files into MATLAB data files. The program runs correctly for vector files in most cases. But when it comes to some scalar files, there arises error message as below:

Data indicator: # Begin: Data Binary 4
Little-endian 4-byte detected.
unpack requires a buffer of 4 bytes
Traceback (most recent call last):
  File "D:\OOMMFTools\oommftools\user_interfaces\gui\oommfdecode.py", line 216, in OnDropFiles
    maximum=len(oommf)))
  File "D:\OOMMFTools\oommftools\user_interfaces\gui\oommfdecode.py", line 243, in groupUnpack
    return (decodedArrays, headers, extraData)
UnboundLocalError: local variable 'decodedArrays' referenced before assignment

error

In OOMMF, the relevant quantities of scalar files are saved in the X coordinate, so they are still vectors in fact. Actually I can check scalar files through other ways, and I'm just wondering what goes wrong. Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions