Jaded-Encoding-Thaumaturgy / vs-denoise

VapourSynth denoising, regression, and motion compensation functions
MIT License
18 stars 6 forks source link

DPIR strength=0 still affects image #93

Closed LightArrowsEXE closed 1 year ago

LightArrowsEXE commented 1 year ago

There may be cases where the user wants to only perform DPIR on specific scenes using zoning, and otherwise leave the video untouched. Currently however, strength=0 still changes the image quite substantially. strength=None also doesn't work (despite being given in the typehint), and it simply errors.

See: comp

NSQY commented 1 year ago

Looks like chroma is being resampled too. You can make this obvious by passing something like kernel=Lanczos(taps=10).

Setsugennoao commented 1 year ago

Looks like chroma is being resampled too. You can make this obvious by passing something like kernel=Lanczos(taps=10).

well ofc, it has to go through RGB

Setsugennoao commented 1 year ago

As for the strength, 0.0 is a valid input for the neural network, the issue should be moved to "None isn't accepted", which makes sense since the functions was thought as having a base strength, and the zones were an afterthought. I think i'll be reworking this with zones like other functions.

So, like, strength={None: 10, (100, 200): 50} will be the same as doing strength=10, ranges=[((100, 200), 50)] now.

Then, make None the "do not touch this zone" value.

LightArrowsEXE commented 1 year ago

Fixed in f77afc11433bca135c329e21a18ec06c01f03303. Replacing functionality can be described in a new issue.