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

Artifacts still persist! #1220

Closed
avalbrec opened this issue Nov 7, 2024 · 21 comments
Closed

Artifacts still persist! #1220

avalbrec opened this issue Nov 7, 2024 · 21 comments
Labels
cannot reproduce Unable to reproduce this issue state:Done This issue has been resolved/dismissed state:InProgress This issue is being worked on

Comments

@avalbrec
Copy link

avalbrec commented Nov 7, 2024

Pretty great effort so far (see pic 1), but something is very wrong with how this decodes some videos. I did an upscale of a live-action video and it appears to be perfect, whereas an animated video is unwatchably bad with artifacts (see pic 2).

2024-11-06 09_06_39-from

2024-11-06 18_27_28-e01) Utopia or Deuteranopia processed 1 mp4 - VLC media player

@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

P.S. These were both done using default settings with Realesgran Plus.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 7, 2024

I don't think the issue is with the video itself. The reason why you're getting these artifacts is likely due to the upscaled video being too large, and hardware decoding tends to produce these artifacts when the video is too large. Try turning off hardware decoding and the artifacts should be gone.

@k4yt3x k4yt3x added the false positive This isn't a issue label Nov 7, 2024
@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

I don't think the issue is with the video itself. The reason why you're getting these artifacts is likely due to the upscaled video being too large, and hardware decoding tends to produce these artifacts when the video is too large. Try turning off hardware decoding and the artifacts should be gone.

NOPE - the one that came out fine, and other were both normal SD sources and the live action movie (that came out fine) was 2+ hours long, while the cartoon was only 15-minutes. AND I DID USE Software decoding. If only the logging actually worked here, might get some info, but that window (qt version) doesn't do anything.

@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

THIS REALLY NEEDS proper investigation.

@k4yt3x k4yt3x added type:Bug Something isn't working state:InProgress This issue is being worked on and removed false positive This isn't a issue labels Nov 7, 2024
@k4yt3x
Copy link
Owner

k4yt3x commented Nov 7, 2024

Interesting. If it's not software decoding then it might be some other issue. Could you please provide the following for me to do some tests:

  • Input file for the anime video
  • Your broken output file for the anime video
  • Encoder settings if you changed them

Also fyi, realesrgan-plus isn't meant for anime videos. realesr-animevideov3 is.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 7, 2024

It's a bit too late today so I'll investigate tomorrow. You can share with either Google Drive, wormhole.app, Dropbox, or anything similar.

@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

Good to know - will try the Animevideo one. I have a theory - will try it and get back to you. Initially, I had a lot of trouble with the first video (MKV from a DVD) and it wouldn't even start. After converted to MP4, I had no trouble. The animated video here was done long ago in old MP4 (not H.264). I want to reconvert it to really high-level H.264/265 and retry it. I suspect the optimizations for H.264/H.265 are so high in modern decoding it fixes a lot of this. Will let you know how it goes and/or put the stuff up you requested.

@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

IT WORKED! The issue is solved. The animated video was converted from DVD Ages ago in old MP4 and when converted to an intermediate H.264, the issue is GONE!! So anyone running into artifacts might want to try converting to H.264 in Handbrake or VLC before scaling. Fixed all the issues.

@UntrustWasTaken
Copy link

I'm having the same problem on files that were already natively h264. Is there no way to run realesrgan-plus at 2x resolution? I've tried using the anime ones but they remove too much detail for my use case.

@avalbrec
Copy link
Author

avalbrec commented Nov 7, 2024

I'm having the same problem on files that were already natively h264. Is there no way to run realesrgan-plus at 2x resolution? I've tried using the anime ones but they remove too much detail for my use case.

Mine is working fine now. I wonder if it has to do with older versions of FFMPEG that did the encoding? All of my earlier stuff was on a PPC Mac using a very old version of FFMPEG & Handbrake. I wonder if it wasn't standardized quite yet?

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 7, 2024

@avalbrec I'd still like to get the old file that didn't work if you could. It should be handled correctly so long it can be decoded by FFmpeg. If it didn't then maybe I did something wrong. If you could send it I'll see if I can fix it.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 7, 2024

@UntrustWasTaken The realesrgan-plus model only has a 4x version.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 8, 2024

@avalbrec also could you give 6.1.1 a try to see if it makes any difference?

@avalbrec
Copy link
Author

avalbrec commented Nov 8, 2024

@avalbrec I'd still like to get the old file that didn't work if you could. It should be handled correctly so long it can be decoded by FFmpeg. If it didn't then maybe I did something wrong. If you could send it I'll see if I can fix it.
@avalbrec also could you give 6.1.1 a try to see if it makes any difference?

Will upload in the morning. Can also try the newer version and see if it changes anything.

@avalbrec
Copy link
Author

avalbrec commented Nov 8, 2024

@avalbrec I'd still like to get the old file that didn't work if you could. It should be handled correctly so long it can be decoded by FFmpeg. If it didn't then maybe I did something wrong. If you could send it I'll see if I can fix it.

Here is the file I had trouble with - https://drive.google.com/file/d/1tN8nMaL7DMWRmVtPDyQSMdVTDMrm24Tt/view?usp=sharing is old (pre-h.264 Apple/QuickTime MP4). Works on most things, but doesn't seem to like your decoder. Also, if you have the 6.1.1 version, would be happy to try it on that.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 8, 2024

Thanks I'll try your video. 6.1.1 has already been released last night. You can get it on the releases page.

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 8, 2024

Seems to be running fine on my Linux with A6000:

video
output.mp4

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 8, 2024

Also fine for my Windows + RTX 4080

video
uod.processed.mp4

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 8, 2024

What's interesting is that when I decode this video on Firefox it has artifacts:

screenshot

image

Local playback with mpv is fine:

screenshot

mpv-shot0001

So I suspect it's still just with the decoding of the video.

@k4yt3x k4yt3x added the cannot reproduce Unable to reproduce this issue label Nov 8, 2024
@avalbrec
Copy link
Author

avalbrec commented Nov 9, 2024

Not sure. BUT all I know is that reconverting it fixed my worries. Thanks again!

@k4yt3x
Copy link
Owner

k4yt3x commented Nov 9, 2024

OK, I'm closing this issue then if it's no longer a problem.

@k4yt3x k4yt3x closed this as completed Nov 9, 2024
@github-actions github-actions bot added state:Done This issue has been resolved/dismissed and removed state:InProgress This issue is being worked on labels Nov 9, 2024
@k4yt3x k4yt3x removed the type:Bug Something isn't working label Nov 9, 2024
@k4yt3x k4yt3x added state:InProgress This issue is being worked on state:Done This issue has been resolved/dismissed and removed state:Done This issue has been resolved/dismissed labels Nov 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cannot reproduce Unable to reproduce this issue state:Done This issue has been resolved/dismissed state:InProgress This issue is being worked on
Projects
None yet
Development

No branches or pull requests

3 participants