EPG translation script - an open project - help required.

There are 33 replies in this Thread which was already clicked 6,461 times. The last Post () by Chris230291.

  • My code slows down considerably adding in title. And that not even translating sub-title. Is sub-title actual used on enigma2?

    Maybe best for Chris230291 to post a version of your full code. It seems faster than mine. Although mine is quickish if you just want to translate the description.

    ** A person who feels appreciated will always do more than what is expected **

  • I think there is a rate limit.

    Nothing is getting translated now without a proxy.


    With these settings:


    Code
    #####################################
    # CONFIG##############################
    desired_language = "en"
    translate_titles = True
    translate_sub_titles = False
    translate_descriptions = False
    proxies = {"http": "192.168.1.200:8118", "https": "192.168.1.200:8118"}
    workers = 40
    days_to_translate = 1
    #####################################


    It translates the basic sky de epg in 0h 1m 49s


    I also spotted an error in my if statement that decides if we want to translate it or not.

    Here's the revised script:



    EDIT: I also suggest something like this to combine all guides into 1, before translating.

    This way it doesn't really save anything to disk and I think it's nicer.

    If there's a reason you can't do that on e2, then that's fine, just an idea.



    Parsing the combined guide took me 0h 3m 59s to translate the titles for 1 day.

    • Official Post

    Thanks for the interest and input everyone :beer1:

    I had another go with argos-translate this morning and after much faffing only improved the time by about 20 minutes. I was expecting it to be faster locally than doing things over the net with the likes of google, clearly that is not the case....and from what i have now read about argos-translate... they are working on a new version (2) that is meant to fix a lot of the speed issues.

    Im running a 6 core 12 thread ryzen5 lappie with 16gb memory, so its not complete crap for these sort of tasks ( BTW im deffo going back to Intel with my next machine)

    But im also being very greedy and translating absolutely everything for 5 days and 5 URLS (one of them in my initial script was wrong i was error checking at the time)


    So it looks like google translate is the way to go, 4 hours is simply not practical, i will give deep translate a try now :thumbs up:

    • Official Post
    Code
    .According to google, you are allowed to make 5 requests per secondand up to 200k requests per day. You can wait and try again later oryou can try the translate_batch function

    As always its taking me a while to digest what you guys have posted, :owl:

    im currently trying to sort a decent proxie list out (back to the IPTV hacking days lol )


    :Halloween2:

  • Code
    .According to google, you are allowed to make 5 requests per secondand up to 200k requests per day. You can wait and try again later oryou can try the translate_batch function

    As always its taking me a while to digest what you guys have posted, :owl:

    im currently trying to sort a decent proxie list out (back to the IPTV hacking days lol )


    :Halloween2:

    I use TOR.

    Not sure if there's a precompiled version for your box or if you would have to compile it.


    I actually use this docker image: https://github.com/dperson/torproxy

  • Code
    .According to google, you are allowed to make 5 requests per secondand up to 200k requests per day. You can wait and try again later oryou can try the translate_batch function

    As always its taking me a while to digest what you guys have posted, :owl:

    im currently trying to sort a decent proxie list out (back to the IPTV hacking days lol )


    :Halloween2:

    well i was running my examples non stop for about 3 hours yesterday. Personally I don't think I got blocked anywhere.

    ** A person who feels appreciated will always do more than what is expected **

  • I am following this thread from start, the project looks very interesting and from the input of you all, it looks more promising.


    In my personal openion, offline translation with cache is the best option for several reasons already mentioned in line and online should come next in priority. Maybe I am wrong.


    Anyway, I think basic users like me, with zero coding background, will be happy if all valueble controputions come together in one scrip or plugin....


    Do you think this is possible at this stage?


    Regards.

    • Official Post

    well i was running my examples non stop for about 3 hours yesterday. Personally I don't think I got blocked anywhere.

    yeah its weird, im currently even getting issues using Tor :head banger:

    I will get there, all your guys stuff has been really helpful, and chatGPT is fantastic (and also quite scary TBH)

  • Just ask if you need help.

    It's really very simple.


    The problem with offline translators is... last time I checked, they sucked.

    Slow and simply not as good as google.

    Google tends to do a very good job at not translating literally and instead giving the answer you are actually looking for.

    I.e. giving you the regional name of a show instead of a simple translation.

Your resource for Enigma2 EPG tools

Get downloads and support for Cool TV Guide, CrossEPG, EPG Importer, IPTV EPG, and satellite/cable program guides. Centralized support and downloads for Enigma2 EPG plugins. Find tools for IPTV, satellite, and cable electronic program guides, including EPGImport, Web Grabber, and more.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!