Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: add windows setting of env vars for umls

...

Step

Example

1. If you do not have a UMLS username and password, you may request one at UMLS Terminology Services.

No example

2. Once you have your UMLS username and password, edit the following files. Find the lines in each script that runs java and add the ctakes.umlsuser and ctakes.umlspw parameters to the java command with your credentials. Make sure you substitute your actual ID and password if you cut and paste the example.

Windows:

Code Block
languagenone
<cTAKES_HOME>\bin\runctakesCVD.bat
<cTAKES_HOME>\bin\runctakesCPE.bat

Linux:

Code Block
languagenone
<cTAKES_HOME>/bin/runctakesCVD.sh
<cTAKES_HOME>/bin/runctakesCPE.sh

 

In the examples below, the rest of the lines after  -cp are not shown because you do not need to modify the rest of the line. Do not delete the rest of the line after -cp however.

Code Block
languagenone
java -Dctakes.umlsuser=<YOUR_UMLS_ID_HERE> -Dctakes.umlspw=<YOUR_UMLS_PASSSWORD_HERE> -cp ... 

If you use special characters in your user name or password, you may need to escape them or for windows, place the string in quotes

For example, if your username and password were literally myusername and mypassword, you could insert them before the -cp option so the start of the java command would look like this:

 

Code Block
java  -Dctakes.umlsuser=myusername  -Dctakes.umlspw=mypassword  -cp ... 

Windows:

 If you use special characters in your umls user name or password, you can place them in double-quotes:

Code Block
java  -Dctakes.umlsuser="myuser!!!!"  -Dctakes.umlspw="mypass!!!!"  -cp ... 

The rest of the line after  -cp is not shown because you do not need to modify the rest of the line. Do not delete the rest of the line after -cp however.

 Linux:

 If you use special characters in your user name or password, you may need to escape them

2a. You may also specify your UMLS Credentials as environment variables to your operating system, but the dots will need to be replaced with underscores.

LinuxWindows:

 

Code Block
REM this sets it for the current command window
set  ctakes_umlsuser=YourUmlsUserId
set  ctakes_umlspw=YourUmlsPassword

 

Linux:

Code Block
languagebash
export ctakes_umlsuser=myusername
export ctakes_umlspw=mypassword

...