Skip to content

Conversation

@xiaoyachong
Copy link
Contributor

@xiaoyachong xiaoyachong commented Jun 9, 2025

Issue in real_image_sim_cli.py
The original code contains the following lines:

with os.read(file) as filebytes:
    image = Image.frombytes(filebytes)

This is problematic for two reasons:

  • os.read() requires two arguments: a file descriptor and the number of bytes to read.
  • Image.frombytes() requires more information, such as the image mode, size, and raw byte data.

In my first commit, I’ve modified the code to use Image.open(file) instead, which correctly reads and loads the image.
In my latest commit, I read image from tiled instead of local file repo and send valid tiled url, so that we can see the heatmap in LSE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant