Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Step

Example

1. Open a command prompt and change to the cTAKES_HOME directory:

Note

Note that <cTAKES_HOME>/bin must be your current directory unless you are skilled at setting paths on your machine.


Windows:

Code Block
languagenone
cd \apache-ctakes-3.0.0-incubating\bin

Linux:

Code Block
languagenone
cd /usr/local/apache-ctakes-3.0.0-incubating/bin

2. Start the collection processing engine by running this command:
The application may take a minute to start on slower hardware.

Windows:

Code Block
languagenone
runctakesCPE.bat

Linux:

Code Block
languagenone
runctakesCPE.sh

The application may take a minute to start on slower hardware.

No example

3. This will bring up the Collection Processing Engine Configurator. In the Menu bar click File >Open CPE Descriptor

4. Navigate to the file

Code Block
languagenone
<cTAKES_HOME>/desc/ctakes-clinical-pipeline/desc/collection_processing_engine/test_plaintext.xml

Click Open.

Info

If you have been directed here as a developer the first "desc/" will not be in the path.

No example

5. Click the Play button (green/blue play arrow near the bottom).

6. You should see that one document was processed. You did process a collection of documents. In this case the collection only contained one just to show how to do it. Close the results window.


7. Close the CPE application. You may be prompted to save changes. Since this was just a test you may click the No button.

 

8. Open a new command prompt and change to the <cTAKES_HOME>

 

9. To test the results there is a comparison tool that will help show that the results match expectations with the following syntax:

Code Block
languagenone
java -cp ctakes-utils-3.0.0.jar org.apache.ctakes.utils.xcas_comparison.Compare
<First File> <Second File> <diff-html>

Where: <First File> is the first file to compare; <Second File> is the second file to compare; <diff-html> is where the results are written to
Copy and paste the example at the right (next cell) which has had our
example files already substituted into a command prompt to run. In this
case we have shipped an example of what the output should be for you to
compare against.

Windows:

Code Block
languagenone
java -cp ctakes-utils-3.0.0.jar org.apache.ctakes.utils.xcas_comparison.Compare ^
"testdata\cdptest\testoutput\plaintext\sample_note_plaintext.xml" ^
"testdata\cdptest\testsampleoutput\plaintext\sample_note_plaintext.xml" ^
c:\stuff\diff-html.html


Linux:

Code Block
languagenone
java -cp ctakes-utils-3.0.0.jar org.apache.ctakes.utils.xcas_comparison.Compare \
"/usr/bin/cTAKES3.0/testdata/cdptest/testoutput/plaintext\sample_note_plaintext.xml" \
"/usr/bin/cTAKES3.0/testdata/cdptest/testsampleoutput/plaintext/sample_note_plaintext.xml" \
/tmp/diff-html.html

10. The resulting file will open for you. Look at the comparison to see the annotations resulting from this pipeline.
Windows:

Code Block
languagenone
c:\stuff\diff-html.html

Linux:

Code Block
languagenone
/tmp/diff-html.html

 

...