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

Signed-off-by: NIKESH KRISHNAN <tesseract12345678@gmail.com> #11

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nikeshkrishnan
Copy link

ISSUE WHILE RUNNING generate_rgb_data.py:
TypeError: Layout of the output array is incompatible with cv::Mat (step[ndims-1] != elemsize or step[1] != elemsize*nchannels)

FIx:

CHANGE rgb_clean = rgb_clean[padh[j]:-padh[j],padw[j]:-padw[j],:]
rgb_noisy = rgb_noisy[padh[j]:-padh[j],padw[j]:-padw[j],:]

TO
rgb_clean = rgb_clean[padh[j]:-padh[j],padw[j]:-padw[j],:].copy()
rgb_noisy = rgb_noisy[padh[j]:-padh[j],padw[j]:-padw[j],:].copy()

ISSUE WHILE RUNNING generate_rgb_data.py:
TypeError: Layout of the output array is incompatible with cv::Mat (step[ndims-1] != elemsize or step[1] != elemsize*nchannels)

FIx:

CHANGE      rgb_clean = rgb_clean[padh[j]:-padh[j],padw[j]:-padw[j],:]
            rgb_noisy = rgb_noisy[padh[j]:-padh[j],padw[j]:-padw[j],:]

TO
            rgb_clean = rgb_clean[padh[j]:-padh[j],padw[j]:-padw[j],:].copy()
            rgb_noisy = rgb_noisy[padh[j]:-padh[j],padw[j]:-padw[j],:].copy()
@nikeshkrishnan
Copy link
Author

ps -I ran using python3

@DongRick
Copy link

thank you!

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.

2 participants