VideoHelp Forum




+ Reply to Thread
Page 2 of 2
FirstFirst 1 2
Results 31 to 44 of 44
  1. You identify the 1st frame to be replaced, eg. check in avspmod

    Enter the values for the 1st 3 entries, in this example it starts at 25 (randomly chosen). So drag a marquee box around the data and drag down the bottom right corner until you reach how far you want to go (you know the total #frames from previewing in avspmod) . Copy & paste that into the relevant section in the .avs script

    It's faster if you use gavino's method, and you don't have to figure out how long or how far to go. You only need to identify the 1st frame to be replaced, then adjust the 3 lines
    Image Attached Images  
    Last edited by poisondeathray; 20th Aug 2011 at 11:43.
    Quote Quote  
  2. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by poisondeathray View Post
    It's faster if you use gavino's method, and you don't have to figure out how long or how far to go. You only need to identify the 1st frame to be replaced, then adjust the 3 lines
    Yes, that's right - that was the motivation for my method.
    Quote Quote  
  3. Thanks Gavino, your method does seem faster.

    If I am correct all that needs to be done is to change the second number in the parenthesis. The first number will always be 15 but the second will be "what + 15 = the first frame number there is an error"

    Is this correct?

    I am getting this error message:
    Avisynth open failure:
    DeleteEvery: frame offsets must be in range [0, period)
    (F:\Nate and Phil's Stuff\Aug. 6th Wedding\GH2 1\DV gavino.avs, line 11)
    Image Attached Files
    Quote Quote  
  4. You need to change all 3 (they should all read 15,16 assuming 1st bad frame 31) , and all match (you forgot to change line 9)

    Compare the syntax to previous example
    Quote Quote  
  5. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by poisondeathray View Post
    You need to change all 3 (they should all read 15,16 assuming 1st bad frame 31)
    No, they should all be (15, 1).
    Note the error message:
    Originally Posted by NBninja8 View Post
    DeleteEvery: frame offsets must be in range [0, period)
    Of course, this will also change frames 1 and 16, but based on your earlier comment that should not matter.
    Quote Quote  
  6. Originally Posted by Gavino View Post
    Originally Posted by poisondeathray View Post
    You need to change all 3 (they should all read 15,16 assuming 1st bad frame 31)
    No, they should all be (15, 1).
    Note the error message:
    Originally Posted by NBninja8 View Post
    DeleteEvery: frame offsets must be in range [0, period)
    Of course, this will also change frames 1 and 16, but based on your earlier comment that should not matter.
    I see, but doesn't 15,16 do the same thing (except frame 1)

    To test, I used

    Code:
    blankclip()
    showframenumber()
    selectevery(15,x)
    Using "15,1" results in: 1,16,31,46,61,...
    Using "15,16" results in almost the same thing, but without the 1st frame: 16,31,46,61,...

    But since you want to start at "31" in this example, wouldn't that be a preferrable result ? (Not that it would make a big difference, since the 1st few frames are usually junk in his case)
    Quote Quote  
  7. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by poisondeathray View Post
    I see, but doesn't 15,16 do the same thing (except frame 1)

    To test, I used

    Code:
    blankclip()
    showframenumber()
    selectevery(15,x)
    Using "15,1" results in: 1,16,31,46,61,...
    Using "15,16" results in almost the same thing, but without the 1st frame: 16,31,46,61,...
    That works with SelectEvery, but DeleteEvery does not allow the offset (here) to be greater than 14 (15-1).

    But since you want to start at "31" in this example, wouldn't that be a preferrable result ? (Not that it would make a big difference, since the 1st few frames are usually junk in his case)
    It would be preferable, but I assumed it didn't matter from what you said previously about the starting frames being junk.
    If it's a problem, just add the original frame 16 back in again at the end:

    ...
    replace = interpolated.SelectEvery(15, 1) # replacement frames

    orig = last
    DeleteEvery(15, 1) # delete bad frames
    InterleaveEvery(replace, 15, 1) # replace deleted frames
    orig.Trim(0, 29) + last.Trim(30, 0) # use original frames 0-29
    Quote Quote  
  8. Originally Posted by Gavino View Post
    That works with SelectEvery, but DeleteEvery does not allow the offset (here) to be greater than 14 (15-1).
    OK, I see that now, thanks for explaining . I should have tried the whole function on a test clip
    Quote Quote  
  9. I'm not following.

    So every parenthesis should be (15,1) but where do I set the offset?
    Quote Quote  
  10. Originally Posted by NBninja8 View Post
    I'm not following.

    So every parenthesis should be (15,1) but where do I set the offset?
    x is the offset from frame zero
    (15,x)

    so 15,1 would mean 1,16,31,...
    so 15,5 would mean 5,20,35,...

    So if the 1st frame to be replaced was 34, you would use 15,4 , because that would replace 4,19,34...
    Quote Quote  
  11. have a look at my script.

    I'm tring to find what the bad frame is by using virtualdubmod. I'm working with clip 00186, the same
    one I uploaded.
    Though sometimes the badframe shows up when previewing the file in virtualdubmod on frame 20,
    sometimes frame 23, sometimes frame 22. It's really frustrating. The script doesn't work either
    but I believe that is because I can't find the right frame.
    Is there another program that I can use to find the where the first bad frame is? And do you have any idea
    why it shows up as 20 sometimes, 23 sometimes ect?

    What process did you use when finding the first bad frame?
    Image Attached Files
    Quote Quote  
  12. have a look at my script.

    I'm tring to find what the bad frame is by using virtualdubmod. I'm working with clip 00186, the same
    one I uploaded.
    Though sometimes the badframe shows up when previewing the file in virtualdubmod on frame 20,
    sometimes frame 23, sometimes frame 22. It's really frustrating. The script doesn't work either
    but I believe that is because I can't find the right frame.
    Is there another program that I can use to find the where the first bad frame is? And do you have any idea
    why it shows up as 20 sometimes, 23 sometimes ect?

    What process did you use when finding the first bad frame?

    Maybe you didn't save script changes ?




    When you examine the video, use only the 1st line

    e.g
    FFMpegSource2("video.dv", atrack=-1)

    That way it's only the video "as is", no filters.

    Once you have identified the 1st "bad" frame and made sure the pattern holds (every 15th frame), then adjust the script, then save it. That is your "new script"

    *Editing scripts is alot easier in avspmod than vdubmod. Push f5 for preview




    Your current script does not match, currently it's this:

    Code:
     
    replace = interpolated.SelectEvery(15, 5) # replacement frames
    DeleteEvery(15, 1) # delete bad frames
    InterleaveEvery(replace, 15, 5) # replace deleted frames
    But 15,5 and 15,1 are different, The numbers in the last 3 lines have to match . The DeleteEvery line is different, it should read 15,5 assuming you want 5,20,35,..... but that clip "00186.dv" used 15,6 if you download the one I uploaded earlier

    It should be this if you wanted 15,5:

    Code:
     
    replace = interpolated.SelectEvery(15, 5) # replacement frames
    DeleteEvery(15, 5) # delete bad frames
    InterleaveEvery(replace, 15, 5) # replace deleted frames

    The actual values for 00186.dv were 15,6 because "21" was the 1st "bad" frame

    Code:
     
    replace = interpolated.SelectEvery(15, 6) # replacement frames
    DeleteEvery(15, 6) # delete bad frames
    InterleaveEvery(replace, 15, 6) # replace deleted frames
    Last edited by poisondeathray; 22nd Aug 2011 at 20:09.
    Quote Quote  
  13. Okay I'll try this. The reason I had:
    DeleteEvery(15, 1) # delete bad frames

    Instead of

    DeleteEvery(15, 6) # delete bad frames

    was because I got the error message about:
    DeleteEvery: frame offsets must be in range [0, period)

    But thanks for your suggestion about viewing the video in virtualdubmod or avspmod without any filters applied,
    that must have been why I was getting the problems.
    Quote Quote  
  14. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Originally Posted by NBninja8 View Post
    The reason I had:
    DeleteEvery(15, 1) # delete bad frames

    Instead of

    DeleteEvery(15, 6) # delete bad frames

    was because I got the error message about:
    DeleteEvery: frame offsets must be in range [0, period)
    You should only get that message if the second number is greater than 14 - like when you had 16 in an earlier post.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!