Skip to content

ResetImagePixels: Assertion `image != (Image *) NULL' failed. #530

Answered by emcconville
DanKrt82 asked this question in Q&A
Discussion options

You must be logged in to vote

The error means that the pixel data was removed from memory before the rest cycle completed. Possibly due to limited resources, but I would suspect that Python's fastbin saw wandImage(wandImage.from_array(...)) and optimized it away. Try this...

with wandImage.from_array(np_array, b'R') as img:
    ....

Note: I'm assuming you want b'R' as this is a grayscale image, not b'I' which would be index.

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@DanKrt82
Comment options

@emcconville
Comment options

@DanKrt82
Comment options

@DanKrt82
Comment options

Answer selected by DanKrt82
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants