画像文字のテキスト化Ⅲ

新聞記事,タイプ印字,手書きの場合

はじめに

Google ドキュメントによる文字認識 (OCR) の方法が, 最初に紹介した内容 (2012) と変わっているので, 手順を以下に示した.

1. Google ドライブに OCR を行いたい画像または PDF をアップロードする.

2. アップロードしたファイル右クリックすると, メニューが表示される.

「アプリで開く」 を選択し, 次いで Google ドキュメント」をクリックする.

新聞記事

以下のような記事,二段組,間に横書きタイトルがある場合,文字の認識は正確ではあるが,上から下へ,右から左に読み込んだだけである.それぞれのブロックを切り出して認識させるほか現在のところ手はない例のひとつである.

期間と一

玄察の子孫にあたる渡慶泉さん2年から、1701年 と、寄贈された年代記

までの出来事が記録さ =県立図書館

れている。 「玄察は自分の身の回 りで起こったことのほ か、加藤家の改易や細 川忠利の入国といった 過去の事柄、地震や大 風が起きた年代、疫病 が流行して人々が苦し む様子などを書き残し ている。

うち2冊には「文政 三年辰年六月 濱町 様御内覧」と書かれて おり、第8代藩主の細 川斉益(濱町様)が目 を通したことが分か る。「学者肌の斉弦は、 価値ある史料として読

んだのだろう。緻密な 江戸時代の熊本の天

文字で書かれており、 候や災害、穀物の相場、

玄察はかなりの知識人 「藩主の動向などを記し

だ」と同館の青木勝士 た年代記「渡邊察日

学芸参事。「半年ほど 記」が、県立図書館(熊

かけて内容を調査し、 一本市中央区)に寄贈さ

公開したい」としてい れた。館は「地域の歴 史が分かる貴重な史

寄贈した泉さんは 料」としている。

「大切にしてきたが、 渡邊玄察は、甲佐町

個人で管理するには限 にある厳島神社の神

界がある。きちんと保 主。子孫の渡邉ん

管していただけるとあ (8)=御船町=が日記

りがたい」と話してい 「などを保管。玄察のほ かの年代記「拾集物

年代記の一部は「拾 語」「拾集昔語」など

集物語」として「肥後 と合わせて計7冊を寄

文献叢書 第4巻」(日 贈した。いずれも縦%

本談義社、1956年 ぎ、横如程度で、合

刊)に収められている。 計約560に上る。

(飛松佐和子) 玄察が生まれた163

る。

記子孫が寄贈 県立図書館 江戸時代の熊本記録

玄察日

る。


配置を変え,隙間を空けると各ブロックを認識し,かなり改善される.縦書き部分の上下ブロックが混じり合うようなことはない.

玄察の子孫にあたる渡邊泉さん と、寄贈された年代記

=県立図書館

2年から、1701年 までの出来事が記録さ れている。 「玄察は自分の身の回 りで起こったことのほ か、加藤家の改易や細 川忠利の入国といった 過去の事柄、地震や大 風が起きた年代、疫病 が流行して人々が苦し む様子などを書き残し ている。 うち2冊には「文政 三年辰年六月 濱町 様御内覧」と書かれて おり、第8代藩主の細 川斉弦濱町様)が目 を通したことが分か る。「学者肌の斉益は、 価値ある史料として読 んだのだろう。緻密な 文字で書かれており、 玄察はかなりの知識人 だ」と同館の青木勝士 学芸参事。「半年ほど かけて内容を調査し、 公開したい」としてい る。

寄贈した泉さんは 「大切にしてきたが、 個人で管理するには限 界がある。きちんと保 管していただけるとあ りがたい」と話してい

「渡邊玄察日記」子孫が寄贈

県立図書館 江戸時代の熊本 記録

江戸時代の熊本の天 候や災害、穀物の相場、 藩主の動向などを記し た年代記「渡邊玄察日 記」が、県立図書館(熊 本市中央区)に寄贈さ れた。館は「地域の歴 史が分かる貴重な史 料」としている。

渡邊玄察は、甲佐町 にある厳島神社の神 主。子孫の渡邉ん (8)=御船町=が日記 などを保管。玄察のほ かの年代記「拾集物 語」「拾集昔語」など と合わせて計7冊を寄 贈した。いずれも縦 、横効程度で、合 計約560に上る。 玄察が生まれた163

る。

年代記の一部は「拾 集物語」として「肥後 文献叢書 第4巻」(日 本談義社、1956年 刊)に収められている。

(飛松佐和子)

ページを複数のブロックに分けて画像を切り出すのは面倒である.ページ単位でOCR処理するためには,一部の市販OCRソフトのようにブロックを枠で囲んで指定できるような改善が望まれる.

英文

2017年ノーベル平和賞の講演の最初の部分の画像文字である.当たり前かもしれないが,英文の場合は認識は完璧である.

Your Majesties, Distinguished members of the Norwegian Nobel Committee, My fellow campaigners, here and throughout the world, Ladies and gentlemen,

It is a great privilege to accept this award, together with Beatrice, on behalf of all the remarkable human beings who form ICAN movement. You cach give me such a tremendous hope that we can -- and will -- bring the era of nuclear weapons to an end. I speak as a member of the family of hibakusha .. those of us who survived the atomic bombing of Hiroshima and Nagasaki For more than seven decades, we have been working hard for the total abolition of nuclear weapons. We have stood in solidarity with those harmed by the production and testing of these horrific weapons around the world.

タイプライター印字論文

次の例はHeterocycles(1979)の単結晶回析の記述部分のOCR処理結果である.当時の速報誌は「カメラレディー原稿論文」が主で,投稿者が版下原稿を用意していた.したがって,特殊文字はタイプライターによっては対応できないことがあった.本例では,ギリシャ文字(α,β,γ,θ,λ)は手書きではないが認識度は低い.それ以外の英数字は文字認識に誤りはない.

Single crystals of IV were obtained from ethanol-acetone solution by slow

evaporation at room temperature. Unit cell dimensions were obtained from least

squares refinement of the 20 angles of 15 reflections measured on a Syntex PĪ

automated diffractometer (Mo, 1=0.71069 À). The crystals are triclinic, space group pī, there are two molecules in the unit cell of dimensions a=9.9201, b= 12.5030, c=9.1718 A, a=106.40, B=105.46, y=97.41°. Intensity data were collected

using the 9-20 scan technique and of the 3530 independent reflections within the

range of the diffractometer (20>55°), 2792 were observed. The orientation of the major part of the molecule was found by direct phasing, but difficulty was ex

perienced in finding a correct phasing model owing to two overlapping molecules.

The middle positions of the both models were used for phase determination (29

atoms). The position of remaining atom was obtained from a difference Fourier map.

Refinements were carried out by the block-diagonal least-squares method using isotropic temperature factors for the hydrogen with exception of the hydrogen atoms of ethyl group with high temperature factors and anisotropic temperature factors for the remaining atoms. Pinal R value was 0.053 for the observed reflec

tion.

ついでに フリーオンラインOCRサービスの利用

類似のサービスを提供しているFREE ONLINE OCR SERVICEを利用したテキスト変換結果を以下に示す.ワード形式に変換すると図入りでオリジナルに近いレイアウトに変換される.複数ページの変換には登録が必要である.

Single crystals of IV were obtained from ethanol-acetone solution by slow

evaporation at room temperature. Unit cell dimensions were obtained from least-

squares refinement of the 20 angles of 15 reflections measured on a Syntex PI

automated diffractometer (Mo, 1=0.71069 A). The crystals are triclinic, space

group F1, there are two molecules in the unit cell of dimensions a-9.9201, los

12.5030, c=9.1718 A, m.106.40, 6.105.46, y=97.41°. Intensity data were collected

using the 0-20 scan technique and of the 3530 independent reflections within the

range of the diffractometer (20155.),2792were observed. The orientation of the

major part of the molecule was found by direct phasing'), but difficulty was ex-

perienced in finding a correct phasing model owing to two overlapping molecules.

The middle positions of the both models were used for phase determination (29

atoms). The position of remaining atom was obtained from a difference Fourier map.

Refinements were carried out by the block-diagonal least-squares method')

using isotropic temperature factors for the hydrogen with exception of the hydro-

gen atoms of ethyl group with high temperature factors and anisotropic temperature

factors for the remaining atoms. Final R value was 0.053 for the observed reflec-

tion.

手書き文書

次の例で示す程度の認識は可能である.

特70 5:1 武藤嚴男 与?野東風 同編 古城閒?吉

肥後美?獻叢書

東京陸?文館藏啟?


特70 5−1 武藤嚴男 宇野東風 古城貞吉同編 第一巻

肥後文献叢書

東京隆文館蔵版

もう一つの例

健康長寿十則

二少肉多菜 一少盘。

一少棉多果 少食

一少愁多笑 一少煩多

少言多行「少欲多

一少夜多浴「小車多步

步施眠組

とがき

無料のアプリなので多くは望めないが,すこし前処理することを厭わなければ実用的なアプリと言える.英文の印刷物に関しては,ほとんど問題ない.

学会誌がPDFファイルとしてデータベース化されるようになったのは前世紀末に電子投稿するようになってからである.それ以前の古い巻号のものは写真を撮りPDF化されているため,キーワードによる検索ができない.将来的には画像文字の論文はOCR処理した形式に変換すべきである.アメリカ化学会の1980年代の雑誌,Tetahedron Lett., Heterocyclesなどは1985年以降はPDFで読むことができる.しかし,テキスト抽出ができる論文は今世紀に入ってからである.例えば,薬学会の英文雑誌は2018年で66巻になるが,テキスト形式のPDFは2001年以降の18巻程度である.画像英文論文のテキスト化は和文と異なり,エラーが少ないので,AIで自動化される段階にきているはずである.「昔はユーザーがテキスト化する必要があった」と語られるのはそんなに遠い将来のことではないと思っている.

2021.5.3