Fixing grain and deinterlacing? (Code Geass)

This forum is for questions and discussion of all the aspects of handling your footage. If you have questions about capturing/ripping footage, AviSynth, or compression/encoding/converting, look here.

Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Tue Jul 23, 2013 7:42 pm

Hello, so I have two questions regarding a Code Geass AMV I'm working on.

One thing I was told by another user is that there's a deinterlacing issue, that I don't know how to fix.

Spoiler :
[img]]http://i762.photobucket.com/albums/xx268/mastamindamv/geass2_zps95df1f9b.jpg[/img]
Image


The first one's a frame where the motion/shake has her up. In the second one, she moves down relative to the camera. You can see some of the green tint, from what's probably the previous frame, right above her hair. It's slight, but if's there. It might be there in the original animation, or its some kind of deinterlacing issue. Does anyone know how to fix this?

Secondly, I've noticed a lot of what I think is noise?

Spoiler :
Image
Image
Image


I'm not exactly sure how to fix this either (if I'm even identifying this correctly).

Please let me know if you guys have any idea how to fix these issues.

Regards,

Dexter

P.S. Here is the AVS script I used for all my Code Geass DVD's

Mpeg2Source("K:\Revolution\Source Footage\Code Geass\1-5\MainMovie\CG 1-5\VIDEO_TS\CG 1-5.d2v", cpu=4)
LUTDeRainbow()
ConvertToYV12()
Spline36Resize(848,480)
#TTempSmooth()
FastLineDarkenMod()
LSFmod(strength=120)
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Tue Jul 23, 2013 7:45 pm

I don't know why I can't edit my post, here's the fixed comparison from the first issue:

Spoiler :
Image
Image
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby l33tmeatwad » Tue Jul 23, 2013 9:15 pm

Dext3r wrote:Mpeg2Source("K:\Revolution\Source Footage\Code Geass\1-5\MainMovie\CG 1-5\VIDEO_TS\CG 1-5.d2v", cpu=4)
LUTDeRainbow()
ConvertToYV12()
Spline36Resize(848,480)
#TTempSmooth()
FastLineDarkenMod()
LSFmod(strength=120)

First off, how are you removing the interlacing, was it soft telecined and you used force film? Additionally, since the artifacts (as it appears) in those samples are going vertically, it isn't interlacing (as that would be horizontal), that would be aliasing. Secondly, with TTempSmooth() commented out (with the # in front of it) you have NO noise reduction set (outside of the deblocking in mpeg2source). Third, why are you using a derainbow filter? I'm fairly certain those DVDs do not have a rainbow issue (maybe I'm wrong).

To be honest, most of your questions about cleaning up the source are answered in this guide here on the org.
Guides, Scripts, & Software: AMV 101 | AMVpack | AviSynth 101 | Anime Upscale
PixelBlended Studios: Website | Facebook | Tumblr | Twitter | YouTube
User avatar
l33tmeatwad
 
Joined: 16 Feb 2005
Location: Charleston, SC
Status: Trolling

Re: Fixing grain and deinterlacing? (Code Geass)

Postby mirkosp » Wed Jul 24, 2013 12:35 am

l33tmeatwad wrote:First off, how are you removing the interlacing, was it soft telecined and you used force film?

Most important question to answer, indeed. However...
Additionally, since the artifacts (as it appears) in those samples are going vertically, it isn't interlacing (as that would be horizontal), that would be aliasing.

No, the user reported another issue, specifically the chroma. Compare the two images he posted: in the latter, the coloring of her hair is out of place, as it is above her head.
This could be due to a number of different reason, from issue in source, to bad deinterlace, hence why whomever the other user might be, his suggestion of double checking the deinterlacing isn't too bad per se.
It's just that, without an actual m2v sample of the scene, it's hard to tell.
Honestly I don't think the light aliasing shown there is anything to worry about, and I think "fixing" it would introduce more issues, instead. But something should be done about the chroma, if possible.

Secondly, with TTempSmooth() commented out (with the # in front of it) you have NO noise reduction set (outside of the deblocking in mpeg2source).

I don't think ttempsmooth would be the best choice here anyway, and using mpeg2source's cpu parameter to deblock is a bad way to go about it to boot (so I suggest to change the cpu parameter to 0).
For blocking, mosquito noise, and ringing, I'd suggest a combination of smoothd2, nlmeanscl, and possibly hqdering as well.
As a reminder, stay low with the parameters, as it's better to underfilter than to overcompensate, unless you're doing a frame-based filtering, in which case you can afford to overfilter individual frames. Keep in mind these are all issuess introduced by the encoder (MPEG-2 is especially bad on this, considering how old and limited of a format it is, particularly with DVD restrictions) since it didn't have enough bitrate to properly store the frames, so clearly some frames are going to be in a worse shape than others and would need a different amount of filtering.

Third, why are you using a derainbow filter? I'm fairly certain those DVDs do not have a rainbow issue (maybe I'm wrong).

I think it was his attempt at fixing the chroma problem he has shown in the screenshots.
Anyway, I'd also get rid of:
ConvertToYV12(): Your source already is i420, so using ConvertToYV12() is a NOP() right now, thus useless.
FastLineDarkenMod(): Please don't do line darkening unless you have extremely valid reasons to ─ keep in mind that recent sources (digital ones as opposed to transfers from analog sources, in most cases) do not need it.
LSFmod(strength=120): Please don't sharpen unless you have valid reasons to ─ if it's because of a blur introduced by the denoising/deblocking, see if using better deblocking/denoising parameters or perhaps contrasharpening afterwards are of more help; if it's due to the source being an upscale, inverse upscale back to the original resolution; if it's because the source looks to be somewhat blurry, it might make sense, but first try to understand whether it was an artistic choice or not (possible in recent sources); in older sources, it most likely makes sense if there is a bit of sharpening needed.

To be honest, most of your questions about cleaning up the source are answered in this guide here on the org.

Not quite... I haven't really done almost anything about it yet, but the avtech really does need improvements on a few things, avs filters being one of the most prominent issues.
Image
User avatar
mirkosp
MODkip
 
Joined: 24 Apr 2006
Location: Gallarate (VA), Italy
Status: (」・ワ・)」(⊃・ワ・)⊃

Re: Fixing grain and deinterlacing? (Code Geass)

Postby l33tmeatwad » Wed Jul 24, 2013 3:03 am

mirkosp wrote:No, the user reported another issue, specifically the chroma. Compare the two images he posted: in the latter, the coloring of her hair is out of place, as it is above her head....Honestly I don't think the light aliasing shown there is anything to worry about, and I think "fixing" it would introduce more issues, instead. But something should be done about the chroma, if possible.

I was waiting on an answer to the IVTC answer before going in to that, but derp...I should have pointed that out.

mirkosp wrote:I don't think ttempsmooth would be the best choice here anyway...

Didn't say it was, was just pointing out there was no noise reduction set and was pointing out it was commented out (in case the user did not know).

mirkosp wrote:
To be honest, most of your questions about cleaning up the source are answered in this guide here on the org.

Not quite... I haven't really done almost anything about it yet, but the avtech really does need improvements on a few things, avs filters being one of the most prominent issues.

It indeed does need some updates, but aside from the chroma issue (derp...), the guide doe have acceptable solutions for most of the other noise in the footage.
Last edited by l33tmeatwad on Wed Jul 24, 2013 3:14 am, edited 1 time in total.
Guides, Scripts, & Software: AMV 101 | AMVpack | AviSynth 101 | Anime Upscale
PixelBlended Studios: Website | Facebook | Tumblr | Twitter | YouTube
User avatar
l33tmeatwad
 
Joined: 16 Feb 2005
Location: Charleston, SC
Status: Trolling

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 3:12 am

mirkosp wrote:
l33tmeatwad wrote:First off, how are you removing the interlacing, was it soft telecined and you used force film?

Most important question to answer, indeed. However...
Additionally, since the artifacts (as it appears) in those samples are going vertically, it isn't interlacing (as that would be horizontal), that would be aliasing.

No, the user reported another issue, specifically the chroma. Compare the two images he posted: in the latter, the coloring of her hair is out of place, as it is above her head.
This could be due to a number of different reason, from issue in source, to bad deinterlace, hence why whomever the other user might be, his suggestion of double checking the deinterlacing isn't too bad per se.
It's just that, without an actual m2v sample of the scene, it's hard to tell.
Honestly I don't think the light aliasing shown there is anything to worry about, and I think "fixing" it would introduce more issues, instead. But something should be done about the chroma, if possible.

Secondly, with TTempSmooth() commented out (with the # in front of it) you have NO noise reduction set (outside of the deblocking in mpeg2source).

I don't think ttempsmooth would be the best choice here anyway, and using mpeg2source's cpu parameter to deblock is a bad way to go about it to boot (so I suggest to change the cpu parameter to 0).
For blocking, mosquito noise, and ringing, I'd suggest a combination of smoothd2, nlmeanscl, and possibly hqdering as well.
As a reminder, stay low with the parameters, as it's better to underfilter than to overcompensate, unless you're doing a frame-based filtering, in which case you can afford to overfilter individual frames. Keep in mind these are all issuess introduced by the encoder (MPEG-2 is especially bad on this, considering how old and limited of a format it is, particularly with DVD restrictions) since it didn't have enough bitrate to properly store the frames, so clearly some frames are going to be in a worse shape than others and would need a different amount of filtering.

Third, why are you using a derainbow filter? I'm fairly certain those DVDs do not have a rainbow issue (maybe I'm wrong).

I think it was his attempt at fixing the chroma problem he has shown in the screenshots.
Anyway, I'd also get rid of:
ConvertToYV12(): Your source already is i420, so using ConvertToYV12() is a NOP() right now, thus useless.
FastLineDarkenMod(): Please don't do line darkening unless you have extremely valid reasons to ─ keep in mind that recent sources (digital ones as opposed to transfers from analog sources, in most cases) do not need it.
LSFmod(strength=120): Please don't sharpen unless you have valid reasons to ─ if it's because of a blur introduced by the denoising/deblocking, see if using better deblocking/denoising parameters or perhaps contrasharpening afterwards are of more help; if it's due to the source being an upscale, inverse upscale back to the original resolution; if it's because the source looks to be somewhat blurry, it might make sense, but first try to understand whether it was an artistic choice or not (possible in recent sources); in older sources, it most likely makes sense if there is a bit of sharpening needed.

To be honest, most of your questions about cleaning up the source are answered in this guide here on the org.

Not quite... I haven't really done almost anything about it yet, but the avtech really does need improvements on a few things, avs filters being one of the most prominent issues.


Yes, I used the "Force Film" method in DGindex to remove the interlacing.

To be honest, most of the filters I use here were things that I was using regularly on a lot of different sources, just because I can never tell what I should and shouldn't use, so its a bit of a wake-up call to hear that I shouldn't be using almost ANY of these (especially considering most of my other sources have turned out fine? At least in my opinion).

I'll try a combination of those three to fix the noise and see what I can come up with, thank you. It really is just confusing with so many filters figuring out what to use and what not to use.
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby l33tmeatwad » Wed Jul 24, 2013 3:22 am

Dext3r wrote:Yes, I used the "Force Film" method in DGindex to remove the interlacing.

To be honest, most of the filters I use here were things that I was using regularly on a lot of different sources, just because I can never tell what I should and shouldn't use, so its a bit of a wake-up call to hear that I shouldn't be using almost ANY of these (especially considering most of my other sources have turned out fine? At least in my opinion).

I'll try a combination of those three to fix the noise and see what I can come up with, thank you. It really is just confusing with so many filters figuring out what to use and what not to use.

Yeah, you should redo your d2v to "Honor Pulldown Flags" and use TIVTC to handle the interlacing removal. I would try out some of the filters mirkosp suggested, but take a look at the guide first. The main reason I'm suggesting the guide is the screenshots it provides for many different types of noise that you will commonly face. As mirkosp pointed out, the guide needs updating because there are better ways to handle some of the things pointed out in it, but it is a good starting place for those that don't know much about filtering and will teach you what certain noises are and give you a good place to start from in terms of researching new filters for any particular problem.
Guides, Scripts, & Software: AMV 101 | AMVpack | AviSynth 101 | Anime Upscale
PixelBlended Studios: Website | Facebook | Tumblr | Twitter | YouTube
User avatar
l33tmeatwad
 
Joined: 16 Feb 2005
Location: Charleston, SC
Status: Trolling

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 3:26 am

l33tmeatwad wrote:
Dext3r wrote:Yes, I used the "Force Film" method in DGindex to remove the interlacing.

To be honest, most of the filters I use here were things that I was using regularly on a lot of different sources, just because I can never tell what I should and shouldn't use, so its a bit of a wake-up call to hear that I shouldn't be using almost ANY of these (especially considering most of my other sources have turned out fine? At least in my opinion).

I'll try a combination of those three to fix the noise and see what I can come up with, thank you. It really is just confusing with so many filters figuring out what to use and what not to use.

Yeah, you should redo your d2v to "Honor Pulldown Flags" and use TIVTC to handle the interlacing removal. I would try out some of the filters mirkosp suggested, but take a look at the guide first. The main reason I'm suggesting the guide is the screenshots it provides for many different types of noise that you will commonly face. As mirkosp pointed out, the guide needs updating because there are better ways to handle some of the things pointed out in it, but it is a good starting place for those that don't know much about filtering and will teach you what certain noises are and give you a good place to start from in terms of researching new filters for any particular problem.


Wait, this source is progressive, not interlaced according to DGIndex?

The only reason I'm using the Forced Film on my d2v is because its a film source, which was what was recommended in the guide?

And I've hit that guide before for the filters, but I'm trying to figure out these other ones and I'm confused, do I need to actually download and set all these up or do they exist in the AMVapp?
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby l33tmeatwad » Wed Jul 24, 2013 3:33 am

Dext3r wrote:Wait, this source is progressive, not interlaced according to DGIndex?

Post the info from the txt that DGIndex created.

Dext3r wrote:The only reason I'm using the Forced Film on my d2v is because its a film source, which was what was recommended in the guide?

Not everything in the guides are the perfect solutions :sweat:

Dext3r wrote:And I've hit that guide before for the filters, but I'm trying to figure out these other ones and I'm confused, do I need to actually download and set all these up or do they exist in the AMVapp?

The filters mirkosp suggested are not included in AMVapp, you will need to download them separately and place the required dll files in the plugins folder for AviSynth.
Guides, Scripts, & Software: AMV 101 | AMVpack | AviSynth 101 | Anime Upscale
PixelBlended Studios: Website | Facebook | Tumblr | Twitter | YouTube
User avatar
l33tmeatwad
 
Joined: 16 Feb 2005
Location: Charleston, SC
Status: Trolling

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 3:39 am

l33tmeatwad wrote:
Dext3r wrote:Wait, this source is progressive, not interlaced according to DGIndex?

Post the info from the txt that DGIndex created.

Dext3r wrote:The only reason I'm using the Forced Film on my d2v is because its a film source, which was what was recommended in the guide?

Not everything in the guides are the perfect solutions :sweat:

Dext3r wrote:And I've hit that guide before for the filters, but I'm trying to figure out these other ones and I'm confused, do I need to actually download and set all these up or do they exist in the AMVapp?

The filters mirkosp suggested are not included in AMVapp, you will need to download them separately and place the required dll files in the plugins folder for AviSynth.


Image

I don't know what you mean by a txt created from DGIndex, but here's the preview I use to get all my info (and yes, I know that I need to run this with Honor Pulldown Flags as the setting to get accurate results).
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby mirkosp » Wed Jul 24, 2013 3:47 am

OT, but it might be useful in future: if you hold Alt while pressing Stamp, it'll only save the highlighted panel (so you could make a screenshot of just the information panel).

Anyway, that information panel looks indeed like a soft pulldown source. Which would mean force film should be the correct choice.
However you made the screenshot before it finished indexing the whole thing, so it would be better if you took a screenshot of after the whole source has been indexed. There might be some stray 60i bit amidst the soft pulldown footage, so that might be the cause.
If not, then I'd assume the green issue is either a mastering issue, or a MPEG-2 fuckup.
Image
User avatar
mirkosp
MODkip
 
Joined: 24 Apr 2006
Location: Gallarate (VA), Italy
Status: (」・ワ・)」(⊃・ワ・)⊃

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 3:51 am

mirkosp wrote:OT, but it might be useful in future: if you hold Alt while pressing Stamp, it'll only save the highlighted panel (so you could make a screenshot of just the information panel).

Anyway, that information panel looks indeed like a soft pulldown source. Which would mean force film should be the correct choice.
However you made the screenshot before it finished indexing the whole thing, so it would be better if you took a screenshot of after the whole source has been indexed. There might be some stray 60i bit amidst the soft pulldown footage, so that might be the cause.
If not, then I'd assume the green issue is either a mastering issue, or a MPEG-2 fuckup.


Oh christ, now you're just making me feel bad, I'm supposed to wait for that whole preview to finish? XD

I've NEVER waited for the DGIndex preview to finish, I only ever made sure I wasn't looking at the opening or ending (for obvious reasons since the opening and ending of the show can be running at different settings, like in Code Geass the opening is interlaced).

Also how do I get the HQDering filter to work? I've found the .dll's for SmoothD2 and NLMeansCL (given they're right in those threads); but for HQDering all there is is that wiki page with the source code?
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 3:52 am

mirkosp wrote:OT, but it might be useful in future: if you hold Alt while pressing Stamp, it'll only save the highlighted panel (so you could make a screenshot of just the information panel).

Anyway, that information panel looks indeed like a soft pulldown source. Which would mean force film should be the correct choice.
However you made the screenshot before it finished indexing the whole thing, so it would be better if you took a screenshot of after the whole source has been indexed. There might be some stray 60i bit amidst the soft pulldown footage, so that might be the cause.
If not, then I'd assume the green issue is either a mastering issue, or a MPEG-2 fuckup.


Also, I could've cropped it to that information (I'm just print screening and putting it in paint); I just figured I'd let you see the whole picture of what I was doing.
Dext3r
 
Joined: 18 May 2011

Re: Fixing grain and deinterlacing? (Code Geass)

Postby mirkosp » Wed Jul 24, 2013 4:01 am

Also how do I get the HQDering filter to work? I've found the .dll's for SmoothD2 and NLMeansCL (given they're right in those threads); but for HQDering all there is is that wiki page with the source code?


HQDering is a script, so you make an .avs file, paste the code you can find in that page inside, save the .avs, rename the extension to .avsi and place the .avsi in the plugins folder of avisynth.

Also you don't have to wait the whole preview (if you mean File > Preview)... that's just slow. You can directly do File > Save Project. That just indexes as fast as your cpu allows, so it won't take too long. Take the screenshot after it's done.
Image
User avatar
mirkosp
MODkip
 
Joined: 24 Apr 2006
Location: Gallarate (VA), Italy
Status: (」・ワ・)」(⊃・ワ・)⊃

Re: Fixing grain and deinterlacing? (Code Geass)

Postby Dext3r » Wed Jul 24, 2013 4:05 am

mirkosp wrote:For blocking, mosquito noise, and ringing, I'd suggest a combination of smoothd2, nlmeanscl, and possibly hqdering as well.
As a reminder, stay low with the parameters, as it's better to underfilter than to overcompensate, unless you're doing a frame-based filtering, in which case you can afford to overfilter individual frames. Keep in mind these are all issuess introduced by the encoder (MPEG-2 is especially bad on this, considering how old and limited of a format it is, particularly with DVD restrictions) since it didn't have enough bitrate to properly store the frames, so clearly some frames are going to be in a worse shape than others and would need a different amount of filtering.


Image

Well when I tried to run the first two filters, I got this error for NLMeansCL; am I supposed to do something other than just extract the individual .dll files that it lists in the thread (like do I need to extract any of the other folders that come with them?)
Dext3r
 
Joined: 18 May 2011

Next

Return to Footage Help

Who is online

Users browsing this forum: No registered users and 2 guests