* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Using RADIANCE v1.0
Survey
Document related concepts
Transcript
[email protected] Where are all the different components of RADIANCE? RADIANCE File Structure Part 1 Stores each radiance‐inbox after processing Freeware OCR software used to parse dose sheets The main RADIANCE code lives here Place dose sheets here for processing by RADIANCE The automated pipeline for running RADIANCE RADIANCE File Structure Part 2 Stores RDSRs produced from legacy dose sheet data Stores JPG of dose sheet, XML of DICOM header and OCR output for each dose sheet Java libraries RADIANCE table structure Code to read and write RDSRs (written in Java) Important Configuration Files radiance_config.php Controls the behavior of RADIANCE Configurable features include how much output is displayed when it runs, whether dose sheets are reprocessed even if they are in the database already, whether or not RDSRs are generated, whether dose sheets are renamed by accession # before archival, etc. radiance_RDSRconfig.php Configuration file for writing RDSR versions of legacy dose sheets Controls whether or not files are overwritten if they already exist You can edit these using WordPad or another text editor of your choice. What language(s) is RADIANCE written in? What additional software does it require to run? RADIANCE: Under the Hood The RADIANCE pipeline is a Windows batch file. Most of RADIANCE itself is written in PHP, a web‐enabled scripting language. No special PHP libraries are used but extensive use is made of regular expressions. The code to read and write RDSRs is written in Java and uses the PixelMed API designed by Dr. David Clunie. The sample code for query/retrieve operations from PACS is also written in PHP but performs system calls to dcmtk (http:// dicom.offis.de/dcmtk.php.en), which is an open‐source package for DICOM operations. At present, RADIANCE runs on a standard Windows PC with a web browser, such as XAMPP. The OCR software is included with RADIANCE. How does RADIANCE work? RADIANCE Step By Step 1. Drop DICOM CT dose sheets in the radiance‐root/radiance‐ inbox folder. 2. Double‐click on radiance‐root/radiancepipeline.bat to run the pipeline. 3. RADIANCE will take the dose sheets from the inbox and create a directory under archive‐radiance‐inboxes/ where it stores the original DICOM files. 4. It runs the dcmgocrconvert.bat file under radiance‐root/ DCMGOCR‐bin/ and performs an OCR of each batch file. A text version of the dose sheet, a JPEG version of the dose sheet and an XML version of the DICOM header are generated. RADIANCE Step by Step cont’d 5. The TXT, JPG and XML files are moved to a subdirectory of radiance‐root/radiance/data named OCRinbox‐<date>‐ random# and archived there each time RADIANCE runs. 6. The radiance.php file parses through this directory and extracts the dose parameters from the text version of the dose sheet. It also parses the DICOM study header (in XML form) and pulls out some relevant info. 7. All the data is stored in a database, which you can then export to Microsoft Excel or Microsoft Access (by producing an SQL file and importing that into Access). How do I send dose sheets to the PC running RADIANCE? Setting up your DICOM destination/listener/receiver 1 In order to get dose sheets to your RADIANCE PC directly from your PACS, you can set it up to be a DICOM destination that receives data from the PACS. To do this, pick a name for your RADIANCE PC, e.g. “RADIANCE”, and a port number, e.g., 104, on which it will communicate with the PACS. The name is also known as the AE title. Install the dcm4che toolkit from http://www.dcm4che.org/. Setting up your DICOM destination/listener/receiver 2 Run the following command in a Windows shell or batch file: dcmrcv RADIANCE:104 ‐dest c:\xampp\htdocs\radiance‐root\radiance‐inbox You will probably need to tell your PACS that the RADIANCE PC is a recognized destination by giving it the IP address, AE title and port number. You can test that this works by pushing a single dose sheet from your PACS to the RADIANCE AE title. If it works, one DICOM file should appear in the radiance‐root/radiance‐ inbox folder. How do I query PACS for my CT dose sheets? Getting dose sheets from PACS Every PACS is unique, but should allow you to query for a particular combination of studyUID and seriesUID. CT dose sheets are mostly stored in the same location as follows: Manufacturer Series # Series Description Siemens 501 Patient Protocol GE 999 Dose Report Philips 1 Dose Info Toshiba* 9000* ? In the radiance‐root/radiance folder, there is a script called radiancedcm.php that includes sample code for how to query the PACS (with findscu) and retrieve CT dose sheets (with movescu). Your PACS/IT group can probably provide you with a script that will work for your particular PACS based on these guidelines. findscu and movescu are utilities within dcmtk. *Our understanding is that Toshiba dose sheet series were not consistently named or numbered until recently. Where does the data from my dose sheets go? Navigating the RADIANCE database with XAMPP To access the RADIANCE database after you have set up RADIANCE, open a browser and go to http://localhost/phpmyadmin. If you encounter a login page, type “radiance” for the username and “radiance” for the password (all lower case, no quotes). You may change these but remember to update them in radiance.php, otherwise RADIANCE will not be able to connect to the database. Accessing the Database Click on “radiance” to access the database The RADIANCE Tables Important Data Tables to Know Table Name What It Contains masterdose Individual series dose parameters (kV, mAs, CTDIvol, DLP, phantom type, etc) masterpatient Patient info (DOB, gender, height/size, weight, etc) masterprovider Info about personnel associated with the exam (referring MD, tech, reporting radiologist). Some of this may be consistently blank as it is normally mined from the RIS masterscanner Scanner info (manufacturer, model name, station name, institution name, etc.) mastertotals Total DLP and estimated whole body effective dose, as well as conversion factor used to obtain the latter masterflatfile Flat file constructed from all tables above except masterdose; good one to export to Excel for your own analysis Some Internal System Tables Table Name What It Contains examcodeslookup Effectively, the chargemaster. This should be updated with your own institution/center’s exam codes and descriptions for RADIANCE to work correctly. Make sure that you maintain correspondence with the DoseLookup value! If you do not update it, RADIANCE will try to guess at a matching study based on the study description in the DICOM header. Correct matches are important because this is how the appropriate k factor for the imaged anatomy is chosen. publisheddoselookup Used to look up the appropriate conversion factor based on the DoseLookup field from the examcodeslookup table. filelog Records the date and time when each dose sheet is processed, as well as including its file name (i.e., where it was archived) A Few More Tables Table Name What It Contains ctaccumulateddosedata Table structure to enable construction of RDSRs ctirradiationeventdata “ dataelementsindicomctdosesr “ dataelementsindicomheader “ trackerrors Internal error‐tracking tables validation “ How do I get the data out of RADIANCE to analyze it? Exporting from the RADIANCE database Choose a table from the list on the left, e.g. masterflatfile Exporting from the RADIANCE database Click “Export” Exporting from the RADIANCE database Make sure this box is checked so your data is labeled Choose your format, e.g. Excel Click “Save as file”, then “Go” How do I update the “examcodeslookup” table with my institution/ center’s exam codes? Updating examcodeslookup 1 This is an important step for RADIANCE to function properly. It will try to guess the matching exam code and anatomy‐specific conversion factor if you do not do it, but may not always guess correctly. To update examcodeslookup with your institution/center’s data, follow the preceding instructions on how to export data from the database but export the examcodeslookup table. Open it in Excel and edit it appropriately, making sure to preserve the matching DoseLookup value so that it will correctly find the conversion factor in the publisheddoselookup table when you import it back into the database. Updating examcodeslookup 2 Once you have finished editing in Excel, you will have to save the file as comma separated text (CSV) to import it back into the database. Before you import it back, backup your existing examcodeslookup table by renaming it to “old‐ examcodeslookup”. That way if something goes wrong, you can revert back to the existing version. This is shown on the next two slides. Then, click the “Import” tab, just as you did when you set up the RADIANCE tables initially, and import your newly created CSV file. Make sure the new table is named examcodeslookup, otherwise RADIANCE will generate error messages. Back up the existing examcodeslookup table Next, click the “Operations” tab Click on the examcodeslookup table Back up the existing examcodeslookup table Change the table name to “old‐examcodeslookup”, then click “Go” What if I don’t want to store all the DICOM dose sheets and OCR output after RADIANCE runs? Turning Off Archival By default, RADIANCE archives both the DICOM versions of the CT dose sheets (in radiance‐root/archive‐radiance‐ inboxes) and the TXT/JPG/XML versions (in radiance‐root/ radiance/data). If you want to turn off archival of the DICOM dose sheets, you will have to edit the radiance‐root/ radiancepipeline.bat file. The TXT/JPG/XML files are used by RADIANCE to populate the database. You can delete these manually once you’re sure RADIANCE is working properly at your institution/ center, or you can add code to the end of radiancepipeline.bat to delete them with each cycle. What are the known bugs/ unimplemented features in RADIANCE? Known Bugs/Pending Features 1 Series separation If multiple anatomic parts are imaged simultaneously and the dose sheet is stored under only one accession #, the total estimated dose for all studies is derived from the total DLP for all the studies. For example, if a CT chest/abdomen/pelvis is performed, the dose may appear to be associated only with the chest exam if the dose sheet is stored within that study. This primarily affects the mastertotals table and the estimated whole body doses. The individual series doses are stored in the masterdose table and you can do your statistics on that table instead to get doses separated by individual series. We are actively working on a solution for this and hope to make it available early in 2011. Known Bugs/Pending Features 2 Multi‐page dose sheets At present, if RADIANCE finds the accession number for a study within its database, it will overwrite the existing records. This causes problems with multi‐page dose sheets because RADIANCE will correctly process each individual page but will not correctly interpret them as one giant study. Surprise dose sheet formats RADIANCE has been most extensively tested with dose sheets from Siemens and GE scanners. We recently updated our Philips parsing to reflect the new dose sheet format that was released about a year ago. For Toshiba we can parse the newest dose sheet format (~18 months ago) but may not be able to understand dose sheets from older studies because we had no samples on which to test. If you can send us samples, we can modify the implementation. Known Bugs/Pending Features 3 Updating the examcodeslookup table The contents of this table are derived from the chargemaster used at Penn. For optimal function of RADIANCE, you should update this table with the exam codes/descriptions used at your center/institution. If you do not, RADIANCE will attempt to guess the best matching exam code and use that to pick the correct anatomy‐specific k factor for conversion to estimated whole‐body effective dose. Please note that the entries in the examcodeslookup table are matched with those in the publisheddoselookup table. When you update the examcodeslookup table for information from your own institution, make sure to correctly update the DoseLookup field as well. What are the licensing terms for RADIANCE? Licensing Terms The terms of the license can be found in the LICENSE.txt and LICENSE.pdf documents under radiance‐root/radiance. In short, RADIANCE is open‐source software. You may use, modify and distribute RADIANCE for non‐profit purposes. We ask that you acknowledge RADIANCE in any presentations or publications by citing the Cook et al. November 2010 JACR article. The full citation is provided in LICENSE.txt and LICENSE.pdf. You may not commercialize or incorporate RADIANCE into a commercial product without discussing additional licensing terms with the RADIANCE development team. Want More Information? Please refer to the Users’ Guide for more information on how to get RADIANCE working at your imaging center. You can also visit the RADIANCE Google Group at https://groups.google.com/forum/#forum/radiance‐users for more information. In a pinch, you can email your questions to [email protected]. Thank you for using RADIANCE!