public class OCR
extends java.lang.Object
A class for OCR of GE and Siemens modality dose report screen saves.
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
defaultFileNameOfKnownGlyphs |
| Constructor and Description |
|---|
OCR(AttributeList list) |
OCR(AttributeList list,
int debugLevel) |
OCR(AttributeList list,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
OCR(java.awt.image.BufferedImage image,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
OCR(java.util.List<java.lang.String> screenFilesPaths) |
OCR(java.util.List<java.lang.String> screenFilesPaths,
int debugLevel) |
OCR(java.util.List<java.lang.String> screenFilesPaths,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
OCR(java.lang.String screenFilesPath) |
OCR(java.lang.String screenFilesPath,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doCommonConstructorStuff(AttributeList list,
java.awt.image.BufferedImage image,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
protected void |
doCommonConstructorStuff(AttributeList list,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel) |
AttributeList |
getCommonAttributeList() |
static CTDose |
getCTDoseFromOCROfDoseScreen(OCR ocr,
int debugLevel,
CTIrradiationEventDataFromImages eventDataFromImages,
boolean buildSR) |
static CTDose |
getCTDoseFromOCROfGEDoseScreen(OCR ocr,
int debugLevel,
java.lang.String startDateTime,
java.lang.String endDateTime,
CTIrradiationEventDataFromImages eventDataFromImages,
boolean buildSR) |
static CTDose |
getCTDoseFromOCROfSiemensDoseScreen(OCR ocr,
int debugLevel,
java.lang.String startDateTime,
java.lang.String endDateTime,
CTIrradiationEventDataFromImages eventDataFromImages,
boolean buildSR) |
static CTDose |
getCTDoseFromOCROfToshibaDoseScreen(OCR ocr,
int debugLevel,
java.lang.String startDateTime,
java.lang.String endDateTime,
CTIrradiationEventDataFromImages eventDataFromImages,
boolean buildSR) |
static java.awt.image.BufferedImage |
getEightBitImageSuitableForThresholding(AttributeList list,
int debugLevel) |
static boolean |
isDoseScreenInstance(AttributeList list) |
static boolean |
isGEDoseScreenInstance(AttributeList list) |
protected static boolean |
isGEDoseScreenSeriesNumber(java.lang.String seriesNumber) |
static boolean |
isPossiblyDoseScreenInstance(AttributeList list) |
static boolean |
isPossiblyDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType) |
static boolean |
isPossiblyDoseScreenSeries(AttributeList list) |
static boolean |
isPossiblyDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription) |
static boolean |
isPossiblyGEDoseScreenInstance(AttributeList list) |
static boolean |
isPossiblyGEDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType) |
static boolean |
isPossiblyGEDoseScreenSeries(AttributeList list) |
static boolean |
isPossiblyGEDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription) |
static boolean |
isPossiblySiemensDoseScreenInstance(AttributeList list) |
static boolean |
isPossiblySiemensDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType) |
static boolean |
isPossiblySiemensDoseScreenSeries(AttributeList list) |
static boolean |
isPossiblySiemensDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription) |
static boolean |
isPossiblyToshibaDoseScreenInstance(AttributeList list) |
static boolean |
isPossiblyToshibaDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType) |
static boolean |
isPossiblyToshibaDoseScreenSeries(AttributeList list) |
static boolean |
isPossiblyToshibaDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription) |
static boolean |
isSiemensDoseScreenInstance(AttributeList list) |
static boolean |
isToshibaDoseScreenInstance(AttributeList list) |
static void |
main(java.lang.String[] arg)
Extract the CT dose information in a screen save image using optical character recognition, correlate it with any acquired CT slice images.
|
java.lang.String |
toString() |
public static java.lang.String defaultFileNameOfKnownGlyphs
public OCR(java.lang.String screenFilesPath)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(java.lang.String screenFilesPath,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(java.util.List<java.lang.String> screenFilesPaths,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(java.util.List<java.lang.String> screenFilesPaths)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(java.util.List<java.lang.String> screenFilesPaths,
int debugLevel)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(AttributeList list) throws java.io.IOException, javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(AttributeList list, int debugLevel) throws java.io.IOException, javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(AttributeList list, java.lang.String fileNameOfKnownGlyphs, java.lang.String fileNameToRecordNewGlyphs, int debugLevel) throws java.io.IOException, javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic OCR(java.awt.image.BufferedImage image,
java.lang.String fileNameOfKnownGlyphs,
java.lang.String fileNameToRecordNewGlyphs,
int debugLevel)
throws java.io.IOException,
javax.xml.parsers.ParserConfigurationException,
org.xml.sax.SAXException,
java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic AttributeList getCommonAttributeList()
public static java.awt.image.BufferedImage getEightBitImageSuitableForThresholding(AttributeList list, int debugLevel) throws DicomException
DicomExceptionprotected void doCommonConstructorStuff(AttributeList list, java.lang.String fileNameOfKnownGlyphs, java.lang.String fileNameToRecordNewGlyphs, int debugLevel) throws java.io.IOException, javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionprotected void doCommonConstructorStuff(AttributeList list, java.awt.image.BufferedImage image, java.lang.String fileNameOfKnownGlyphs, java.lang.String fileNameToRecordNewGlyphs, int debugLevel) throws java.io.IOException, javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.lang.Exception
java.io.IOExceptionjavax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.lang.Exceptionpublic java.lang.String toString()
toString in class java.lang.Objectprotected static boolean isGEDoseScreenSeriesNumber(java.lang.String seriesNumber)
public static boolean isPossiblyGEDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription)
public static boolean isPossiblyGEDoseScreenSeries(AttributeList list)
public static boolean isPossiblyGEDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType)
public static boolean isPossiblyGEDoseScreenInstance(AttributeList list)
public static boolean isGEDoseScreenInstance(AttributeList list)
public static boolean isPossiblySiemensDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription)
public static boolean isPossiblySiemensDoseScreenSeries(AttributeList list)
public static boolean isPossiblySiemensDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType)
public static boolean isPossiblySiemensDoseScreenInstance(AttributeList list)
public static boolean isSiemensDoseScreenInstance(AttributeList list)
public static boolean isPossiblyToshibaDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription)
public static boolean isPossiblyToshibaDoseScreenSeries(AttributeList list)
public static boolean isPossiblyToshibaDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType)
public static boolean isPossiblyToshibaDoseScreenInstance(AttributeList list)
public static boolean isToshibaDoseScreenInstance(AttributeList list)
public static boolean isPossiblyDoseScreenSeries(java.lang.String manufacturer,
java.lang.String modality,
java.lang.String seriesNumber,
java.lang.String seriesDescription)
public static boolean isPossiblyDoseScreenSeries(AttributeList list)
public static boolean isPossiblyDoseScreenInstance(java.lang.String manufacturer,
java.lang.String sopClassUID,
java.lang.String imageType)
public static boolean isPossiblyDoseScreenInstance(AttributeList list)
public static boolean isDoseScreenInstance(AttributeList list)
public static CTDose getCTDoseFromOCROfGEDoseScreen(OCR ocr, int debugLevel, java.lang.String startDateTime, java.lang.String endDateTime, CTIrradiationEventDataFromImages eventDataFromImages, boolean buildSR) throws java.io.IOException
java.io.IOExceptionpublic static CTDose getCTDoseFromOCROfSiemensDoseScreen(OCR ocr, int debugLevel, java.lang.String startDateTime, java.lang.String endDateTime, CTIrradiationEventDataFromImages eventDataFromImages, boolean buildSR) throws java.io.IOException
java.io.IOExceptionpublic static CTDose getCTDoseFromOCROfToshibaDoseScreen(OCR ocr, int debugLevel, java.lang.String startDateTime, java.lang.String endDateTime, CTIrradiationEventDataFromImages eventDataFromImages, boolean buildSR) throws java.io.IOException
java.io.IOExceptionpublic static CTDose getCTDoseFromOCROfDoseScreen(OCR ocr, int debugLevel, CTIrradiationEventDataFromImages eventDataFromImages, boolean buildSR) throws java.io.IOException
java.io.IOExceptionpublic static final void main(java.lang.String[] arg)
Extract the CT dose information in a screen save image using optical character recognition, correlate it with any acquired CT slice images.
arg - an array of 1 to 6 strings - the path to a dose screen save image or folder of screens (or "-" if to search for dose screens amongst acquired images),
then optionally the path to a DICOMDIR or folder containing acquired CT slice images (or "-" if none and more arguments)
then optionally the name of Dose SR file to write (or "-" if none and more arguments)
then optionally the file containing the text glyphs to use during recognition rather than the default (or "-" if none and more arguments),
then optionally the name of a file to write any newly trained glyphs to
then optionally the debug level