VideoHelp Forum




+ Reply to Thread
Results 1 to 8 of 8
  1. Member
    Join Date
    Aug 2008
    Location
    Greece
    Search PM
    Hi.

    I have some .srt subtitles that has spaces between the words more than enough.
    Like this

    4
    00:00:58,168 --> 00:01:00,673
    The ho use at ri sing of the s un is n ear

    5
    00:01:02,488 --> 00:01:06,209
    Wh ere did y ou go?

    6
    00:01:06,347 --> 00:01:09,484
    I h ope you are in y our time and do n't late
    Is there any program or any method that can clear all that kind of spaces mostly at greek language(and not at english) that do all that automatically and NOT manual word by word?

    A LOT OF THANKS.
    Quote Quote  
  2. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    Any decent text editor (TextPad, EditPlus, NoteTab, whatever) can do batch-replacement/deletion of characters.
    However I doubt that any of them is "good-enough" at spell-checking (especially when the language is not English), so I fear some corrections will still have to be done manually.
    Last edited by El Heggunte; 6th Feb 2013 at 04:43. Reason: aaaargh
    Quote Quote  
  3. You can "somewhat" automate this if you notice a pattern. In your example I see "y our" is misspelled more than once. In that case you can use notepad's "find and replace" function to automate the replacement of the correct spelling. You what to find "y o" and replace it with "yo". You will have to account for any misspelled words after though, haha.
    Quote Quote  
  4. Member
    Join Date
    Aug 2008
    Location
    Greece
    Search PM
    I know how i can do it MANUALLY but this is not that i want.

    I want to know if i can do that AUTOMATICALLY NOT MANUALLY....
    Quote Quote  
  5. LOL, not fully automated. Machines aren't human beings.
    Quote Quote  
  6. Banned
    Join Date
    Oct 2004
    Location
    Freedonia
    Search Comp PM
    Originally Posted by fits79 View Post
    I know how i can do it MANUALLY but this is not that i want.

    I want to know if i can do that AUTOMATICALLY NOT MANUALLY....
    No. This task is much harder than you realize. This is not the best example, but it's all I can think of. Such a program would have to be smart enough to understand if you really meant to say
    car pet
    or if you meant to say
    carpet
    You're getting into artificial intelligence issues here. This is a very difficult job.
    Quote Quote  
  7. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    Yeah, that would require the machine to be able to guess what you were intending...

    You can always open the file up in MS Word and use their F&R tool. Works really well and includes ability to work with spaces and other "non-character" characters. Just make sure you save as unformatted TXT (if you put quotes around the whole filename+extension while saving, it will retain its original extension).

    For example: Find = <space><space>, Replace=<space> will get rid of extra spaces. (Be sure to run through multiple times until it doesn't find any more)

    But you still have to manually choose how it is to operate...

    Scott
    Quote Quote  
  8. you could, of course write a F&R macro in Word to change many words in one go, but it still wouldn't be fully automated.

    check out my Find and replace Word-macro to correct the "I" in any text file, so also an .SRT file:

    Selection.Find.ClearFormatting
    Selection.Find.Replacement.ClearFormatting
    With Selection.Find
    .Text = " i "
    .Replacement.Text = " I "
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchCase = True
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    With Selection.Find
    .Text = " i'"
    .Replacement.Text = " I'"
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchCase = True
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    With Selection.Find
    .Text = " i^p"
    .Replacement.Text = " I^p"
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchCase = True
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    With Selection.Find
    .Text = "^pi "
    .Replacement.Text = "^pI "
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchCase = True
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    With Selection.Find
    .Text = "^pi'"
    .Replacement.Text = "^pI'"
    .Forward = True
    .Wrap = wdFindContinue
    .Format = False
    .MatchCase = True
    .MatchWholeWord = False
    .MatchWildcards = False
    .MatchSoundsLike = False
    .MatchAllWordForms = False
    End With
    Selection.Find.Execute Replace:=wdReplaceAll
    End Sub
    This would only be efficient if you have many srt. files that are wrong in the same way, a pattern.
    Last edited by KneeRow; 7th Feb 2013 at 18:36.
    Looking for subtitles of: Höök tt0997023, Lime tt0269480, La clé sur la porte tt0077348. tt=iMDb.com Found Desideria tt0081724 subtitle! :-)
    Quote Quote  



Similar Threads

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