Question

How to translate a field from Arabic to English and vice versa?


How to translate a field from Arabic to English and vice versa?,

 

I wonder if there is a way or a command that may help in translation a value from one language to other?

 

 

Best,

 

Majdoleen

13 replies

Userlevel 4
Hi

 

 

I would start by looking at the Google Translate API (https://cloud.google.com/translate/v2/using_rest), it should be relatively easy to access using the HTTPCaller.

 

 

David
Thank you David,

 

But how it will translate al missing value without consuming a lot of time???

 

 

Best,

 

Majdoleen
Userlevel 4
Hi

 

 

Can't you test for missing values first, so that you don't query Google Translate with an empty value? Or am I misunderstanding something?

 

 

If you have a lot of recurring values, you might also want to consider some sort of caching mechanism so you don't end up translating the same string again and again. That should save some time (local lookup vs external call) as well as money (Google Translate bills you per character translated).

 

 

David

 

 
Hi,

 

All I want is to translate all the values which about 5000 at the same GDB and not each value separetly,

 

 

best, Majdoleen
Badge +7
David -  Google Translate API is a paid service. as stated on the link provided.

 

?

 

Majdoleen- so I believe it's a one-time task, right?

 

I can help in bulk translate your file geodatabse, can you share it?

 

 

Sami
Hi Sami,

 

 

Thank you so much, I have more than one file, please could you share the way that you translate it, also I can share the file with you, but as I mentioned I have more than one file GDB.

 

 

Best,

 

Majdoleen

 

 
Userlevel 4
Sami

 

 

Yes, it is a paid service. But it is not very expensive, only 20USD per 1M characters translated.

 

 

If you have more time than money, you can also just copy/paste it into the regular Google Translate GUI, which is free.

 

 

David
Userlevel 4
Badge +13

Hi Majdoleen,

How many records do you have?

Thanks.

Lyes

Hi Lyes,

 

I have different recods, some layers arrive to 250000, and others a round 5000 !!!

 

best,

 

Majdoleen
Userlevel 4
Badge +13

Hi,

I see that it is not a direct translation from what I read, those are names and some would give you the wrong translation using any translation software. For instance: ??? ?????? should be translated as "Jabal El-Najma" and not the "mountain of the star" literrally.

How many locations/places do you have? 100? 1000?

Lyes.

Hi,

 

 

Thousands, and in some layers the missing feild is the english one, and it is not all names !! we have services, facilities, governorates, and cities.(different types of layer )

 

 

Best,

 

Majdoleen
Userlevel 4
Hi

 

 

If you have a lot of repeat values, here's what I'd do:
  • Read alle the tables containing arabic text attributes into one workspace
  • Send all the arabic text attributes through a single DuplicateRemover, so that you only get unique values
  • Write out the unique arabic text values to e.g. an Excel file
  • Get someone who knows arabic to translate your Excel file, this should be much quicker now since they only have to translate every possible value once
  • Use the resulting translated Excel-file as a basis for an AttributeValueMapper (or a SchemaMapper) in your workspace(s)
David

 

 
Badge +7
Majdoleen, I wanted do the scenario as David suggested, but with a slightly difference was to use a [Reader--> SchemaMapper--> Writer] methodology. and yes as David said earlier, you "can also just copy/paste it into the regular Google Translate GUI, which is free."

 

 

Then, as Lyes( MyGIS) mentioned, he's right, you can find some funny Arabic-to-English translations resulted from the Google Translate, which need you to interfere at some point, and later someone has to verify for you (responsible) for the official names of these locations you mentioned (services, facilities, governorates, and cities,..etc)

 

 

My idea is to centralize this master excel file used in the SchemaMapper translator which will be reused as single source for ongoing editing/modifying/maintaining/sharing for future use as well.

 

 

Let us know if you needed further help..

 

 

Sami

Reply