{"id":45632,"date":"2023-08-26T20:20:34","date_gmt":"2023-08-26T19:20:34","guid":{"rendered":"https:\/\/www.roger-pearse.com\/weblog\/?p=45632"},"modified":"2023-08-26T20:20:34","modified_gmt":"2023-08-26T19:20:34","slug":"is-it-possible-to-read-editions-of-amharic-texts-an-experiment","status":"publish","type":"post","link":"https:\/\/roger-pearse.com\/weblog\/2023\/08\/26\/is-it-possible-to-read-editions-of-amharic-texts-an-experiment\/","title":{"rendered":"Is it possible to read editions of Amharic texts?  An experiment"},"content":{"rendered":"<p align=\"justify\"><a href=\"https:\/\/roger-pearse.com\/weblog\/2023\/08\/26\/an-ethiopic-legend-abba-garima-copyied-the-bible-in-a-single-day\/\">In my last post<\/a> I mentioned how the <em>Life of St Garima<\/em> in Ethiopian was printed by Rossini, but without a translation.\u00a0 In fact it has never been translated into any modern language, to my knowledge.\u00a0 I don&#8217;t know any Ethiopian, and I doubt that I ever will.<\/p>\n<p align=\"justify\">But we live in an age of wonders, when it comes to unfamiliar languages.<\/p>\n<p align=\"justify\">So&#8230; is it possible to work with Ethiopian language editions, even if you know no Ethiopian?\u00a0 What about Google Translate?\u00a0 Ethiopian is in this heavy unfamiliar script.\u00a0 Is there OCR for this?\u00a0 If you can scan Rossini&#8217;s edition, can you pop it into Google Translate and get the English?<\/p>\n<p align=\"justify\">There are two sorts of Ethiopian out there, I know.\u00a0 There is Ge`ez, or classical Ethiopian; and there is Amharic, the modern dialect.\u00a0 Rossini printed his text from a 19th century manuscript.\u00a0 So it seems likely that this is in Amharic.<\/p>\n<p align=\"justify\">A quick Google confirmed; Google Translate knows Amharic!\u00a0 A bit of googling found me an Amharic news website online, <a href=\"https:\/\/amharic-zehabesha.com\/\">here<\/a>.\u00a0 I&#8217;m using Chrome, so all I had to do was right-click anywhere and select &#8220;Translate to English&#8221; and the whole website was rendered into some sort of English.\u00a0 And&#8230; it worked!!\u00a0 Yay me!\u00a0 It&#8217;s obviously not 100%, but it&#8217;s way better than 0%!<\/p>\n<p align=\"justify\">So what about OCR?\u00a0 I was sad to see that Abbyy Finereader apparently doesn&#8217;t support Amharic.\u00a0 That&#8217;s a blow.\u00a0 It was developed originally to handle Cyrillic, so it certainly has the capability.\u00a0 But it&#8217;s not offered.\u00a0 Drat.<\/p>\n<p align=\"justify\">A bit of googling brought me to a dubious-looking website <a href=\"https:\/\/pdf.wondershare.com\/ocr\/amharic-ocr.html\">here<\/a>, claiming to offer a selection of tools which could do Amharic OCR.\u00a0 The prose felt a bit machine-generated, so I worried that it was bunk, or worse, a malicious site.\u00a0 But the first option was&#8230; Google Drive.<\/p>\n<p align=\"justify\">I never knew this, but seems that, if you upload a PDF containing an image of text, and then open it in Drive as a Google Docs document, it OCR&#8217;s the content.<\/p>\n<p align=\"justify\">Well, I thought, let&#8217;s give it a try.\u00a0 So I extracted the first page of Rossini&#8217;s edition, using Adobe Acrobat Pro 9 &#8211; no flashy latest-edition stuff going on here!\u00a0 Here&#8217;s a pic:<\/p>\n<p align=\"justify\"><a href=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Rossini_pg1_original.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-45634\" src=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Rossini_pg1_original.jpg\" alt=\"\" width=\"1255\" height=\"856\" \/><\/a><\/p>\n<p align=\"justify\">Then I uploaded it, and opened as a Google document.\u00a0 And &#8230; it just treated the Amharic as an image.\u00a0 Dang!\u00a0 But I noticed that it <span style=\"text-decoration: underline;\">did<\/span> indeed OCR the Italian at the top of the page!<\/p>\n<p align=\"justify\">This is supposed to work.\u00a0 So I thought maybe I should work over the image a bit.\u00a0 I imported the one-page PDF into Abbyy Finereader 15, and chopped off the Italian at the top, and the critical apparatus at the bottom.\u00a0 I then used the image editor in Finereader to &#8220;whiten the background&#8221;.\u00a0 This can be flaky, but this time it worked fine, and I got a pure white background.\u00a0 \u00a0And I got this:<\/p>\n<p align=\"justify\"><a href=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Rossini_pg1_processed.png\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-45635\" src=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Rossini_pg1_processed.png\" alt=\"\" width=\"2799\" height=\"2976\" \/><\/a><\/p>\n<p align=\"justify\">(I&#8217;ve just seen the marginal notes, which I need to chop off as well, so I&#8217;ll have to go round the loop again)<\/p>\n<p align=\"justify\">I exported the image as a PNG, and I used Acrobat again to create a PDF from the image.\u00a0 Then I uploaded the new PDF to Google Drive, and opened it as a Google Docs document.\u00a0 And&#8230; it worked!\u00a0 Sort of&#8230;<\/p>\n<blockquote>\n<p align=\"justify\">\u1260\u1235\u1218 : \u12a0\u1265 : \u12c8\u12c8\u120d\u12f5 &#8216; \u12c8\u1218\u1295\u1348\u1235 \u1361 \u1245\u12f1\u1235 \u1361 \u1369 \u1361 \u12a0\u121d\u120b\u12a8 \u1361 \u120b\u12d5\u120c\u1201 \u1361 \u1270\u12c8 \u12a8\u120d\u12a9\u1361 \u12c8\u1266\u1271 \u1361 \u12a0\u1218\u1295\u12a9 \u1361 \u12a5\u1235\u12a8 \u1361 \u120b\u12d3\u1208\u1218 \u1361 \u12d3\u1208\u121d \u1361 \u12a0\u121c\u1295 \u1362<\/p>\n<p align=\"justify\">\u12f5\u122d\u1233\u1295 \u1361 \u12d8\u12f0\u1228\u1230 \u1361 \u1245\u12f1\u1235 \u1361 \u12ee\u1210\u1295\u1235 \u1361 \u12a4\u1332\u1235 \u1361 \u1246\u1336\u1235 \u1361 \u12d8\u12a0\u12ad\u1231\u121d o \u1361 \u1260\u12a5\u1295\u1270 \u12d5\u1260\u12e9 \u1361 \u12c8\u12ad\u1265\u1229 \u1361 \u1208\u1245\u12f1\u1235 \u1361 \u12ed\u1235\u1213\u1245 = \u12c8\u12ed\u1264 \u1364 \u1235\u121d\u12d1 &#8216; \u12c8\u120d\u1265\u12c9 \u1361 \u12a6\u12a0\u1280\u12cd\u12e8 5 \u134d\u1241\u122b\u1295\u12e8 \u1361 \u12d8\u12a5\u1290\u130d\u1228\u12a8\u1219 \u1362 \u122d\u12a2\u12a9 \u1361 \u1265\u12a5\u1232\u1270 \u1361 \u12a5\u1295\u12d8 \u1361 \u12ed\u12d8\u1265\u1325\u12cb \u1361 \u12d5\u122b\u1243 \u12c8\u12a5\u1295\u12d8 \u1361 \u12ed\u1200\u122d\u1349 \u1361 \u120b\u12d5\u120c\u1203 \u1361 \u12c8\u120b\u12d5\u1208 \u1361 \u12a5\u130d\u12dd\u12a5\u1275\u1290 \u1361 \u121b\u122d\u12eb\u121d \u1361 \u12a5\u1295\u12d8 \u1361 \u12ed\u1265\u1209 \u1260\u12a5\u1295\u1270 \u1361 \u12c8\u120d\u12f3 \u1361 \u12ad\u122d\u1235\u1276\u1235 \u1364 \u12a5\u121d\u1265\u12a5\u1232\u1275 \u1361 \u12aa\u12eb\u1201 : \u12a2\u1270\u12c8\u120d\u12f0 \u1363 \u12ed\u1265\u1209 \u1361 \u12a5\u120b \u1361 \u12a2\u12e8\u12a0\u121d\u1291 \u1361 \u1260\u12ad\u122d\u1235\u1276\u1235 = \u12c8\u12ae\u1295\u12a9 \u1361 \u12a5\u1295\u12d8 \u1361 \u12a5\u1228\u12cd\u133d \u1361 \u12c8\u12a0\u1280\u12dd\u12a9 \u12a5\u1235\u12d0\u121d \u1361 \u1273\u1215\u1270 \u1361 \u12a5\u1308\u122a\u1203 \u1361 \u1208\u12ed\u12a5\u1272 \u1361 \u1265\u12a5\u1232\u1275 \u1361 \u12a5\u1295\u12d8 \u1361 \u1275\u1265\u120d \u1364 \u12a5\u12c8 &#x25aa;\u1260\u12dd \u1361 \u12a0\u1295\u1240\u133d \u1361 \u12c8\u1345\u12a0 \u1361 \u1295\u1309\u1220 \u1361 \u1230\u121b\u12eb\u1275 \u1361 \u12c8\u121d\u12f5\u122d \u1362 \u12c8\u1236\u1260 \u1361 \u1275\u1265\u120d\u1361 \u12a8\u1219\u12dd \u1361 \u12c8<\/p>\n<\/blockquote>\n<p align=\"justify\">That&#8217;s&#8230; rather astonishing.\u00a0 No idea what all that is, but it looks sort of right.\u00a0 Let&#8217;s bear in mind that Rossini printed his edition in 1897.\u00a0 This is not a modern typeface.\u00a0 So this is rather good.<\/p>\n<p align=\"justify\">Next step was to paste it into Google Translate.\u00a0 It set it to auto-detect the language, and pasted in the first bit.\u00a0 And&#8230; it worked.\u00a0 In fact it gave a really useful transcription into Roman letters as well, which makes it a LOT easier to manipulate the text.<\/p>\n<p align=\"justify\"><a href=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Google_Translate_amharic.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-45636\" src=\"https:\/\/roger-pearse.com\/weblog\/wp-content\/uploads\/2023\/08\/Google_Translate_amharic.jpg\" alt=\"\" width=\"1682\" height=\"357\" \/><\/a><\/p>\n<p align=\"justify\">OK, I&#8217;m cheating slightly.\u00a0 The first time I uploaded, the translation ended at &#8220;Spirit&#8221;.\u00a0 But this is a Google Translate bug &#8211; it sometimes omits the remainder of a sentence.\u00a0 If you split the text with a line feed, you often get the rest.\u00a0 And that&#8217;s what I did.\u00a0 I worked out by experiment where I needed to be, and then I got the above.<\/p>\n<p align=\"justify\">I don&#8217;t quite believe the translation of the second sentence either.\u00a0 I suspect I need to play with this a bit to work out what each word is.<\/p>\n<p align=\"justify\">I notice all those colons between every word.\u00a0 It might help if I actually looked up the script online!<\/p>\n<p align=\"justify\">But I think you&#8217;ll agree that this is quite marvellous &#8211; I, who know absolutely nothing about the language, am getting something useful out!<\/p>\n<p align=\"justify\">Magic!<\/p>\n<p align=\"justify\">\n","protected":false},"excerpt":{"rendered":"<p>In my last post I mentioned how the Life of St Garima in Ethiopian was printed by Rossini, but without a translation.\u00a0 In fact it has never been translated into<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"jetpack_seo_schema_type":"","_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_awef_post_faq_schema":[],"_jetpack_hide_featured_image":false,"_jetpack_featured_image_duplicate_dismissed":0,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[19],"tags":[155,654,655,758,889],"class_list":["post-45632","post","type-post","status-publish","format-standard","hentry","category-from-my-diary-announcements","tag-amharic","tag-ethiopian","tag-ethiopic","tag-geez","tag-information-access"],"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/posts\/45632","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/comments?post=45632"}],"version-history":[{"count":0,"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/posts\/45632\/revisions"}],"wp:attachment":[{"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/media?parent=45632"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/categories?post=45632"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/roger-pearse.com\/weblog\/wp-json\/wp\/v2\/tags?post=45632"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}