tberg12 / ocular

Ocular is a state-of-the-art historical OCR system.
GNU General Public License v3.0
250 stars 48 forks source link

Empty Array Error #17

Open bleckley opened 2 years ago

bleckley commented 2 years ago

Hello, I am attempting to initialize a font, and while running, I get the following: Ignoring empty character rendering: Cursor, D Exception in thread "main" java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.simontuffs.onejar.Boot.run(Boot.java:340) at com.simontuffs.onejar.Boot.main(Boot.java:166) Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 at sun.font.CompositeStrike.getStrikeForSlot(CompositeStrike.java:79) at sun.font.CompositeStrike.getFontMetrics(CompositeStrike.java:97) at sun.font.FontDesignMetrics.initMatrixAndMetrics(FontDesignMetrics.java:359) at sun.font.FontDesignMetrics.(FontDesignMetrics.java:350) at sun.font.FontDesignMetrics.getMetrics(FontDesignMetrics.java:302) at sun.java2d.SunGraphics2D.getFontMetrics(SunGraphics2D.java:863) at edu.berkeley.cs.nlp.ocular.image.FontRenderer.renderString(FontRenderer.java:377) at edu.berkeley.cs.nlp.ocular.image.FontRenderer.getRenderedFont(FontRenderer.java:354) at edu.berkeley.cs.nlp.ocular.main.InitializeFont.run(InitializeFont.java:75) at edu.berkeley.cs.nlp.ocular.main.OcularRunnable.doMain(OcularRunnable.java:25) at edu.berkeley.cs.nlp.ocular.main.InitializeFont.main(InitializeFont.java:61) ... 6 more

What array is empty, and how can I overcome this, please? My text sample has letters, numbers, and punctuation, so I'm not sure what is missing.

Thank you, David