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

Bug with non-square images #1

Open
FreddyWordingham opened this issue Aug 30, 2022 · 0 comments
Open

Bug with non-square images #1

FreddyWordingham opened this issue Aug 30, 2022 · 0 comments

Comments

@FreddyWordingham
Copy link
Owner

Noting a known bug when rendering non-square images:

img_0000

I think this is probably in the util.cols_to_image function (I've probably presumed something incorrectly about the png format)

pub fn cols_to_image(arr: &Array3<u8>) -> RgbImage {
    let (width, height, _) = arr.dim();
    RgbImage::from_vec(
        width as u32,
        height as u32,
        arr.as_slice().unwrap().to_vec(),
    )
    .expect("container should have the right size for the image dimensions")
}
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

No branches or pull requests

1 participant