OHDSI Home | Forums | Wiki | Github

Error in executing cpt4.jar

I downloaded the vocabulary files and tried to reconstitute CPT-4 by running cpt4.jav. However, it did not work well and got following error.

[ERROR] 2019-11-03 13:42:14.767 [main] Application - Cannot process CONCEPT.csv file. You can find more details in the logs/logfile.log file.
Reason: java.lang.IllegalStateException: java.lang.UnsupportedOperationException

Do you have any idea to solve this problem?

Thank you!

Hi otaka0721
It should be a logs/logfile.log file in your cpt4 directory. This file contains a detailed description of the error. Could you copy this information and add post it here?

Thank you.

Hi Yaroslav,

Here I paste the log file contents.
Do you have any thoughts about what the cause might be?

Thank you.

[INFO ] 2019-11-03 13:50:10.670 [main] ConceptService - Writing updated data to CONCEPT.csv
[ERROR] 2019-11-03 13:50:24.157 [main] ConceptUpdateService - Cannot open cpt4_ref.csv file
java.lang.UnsupportedOperationException: null
at com.sun.nio.zipfs.ZipFileSystemProvider.ensureFile(ZipFileSystemProvider.java:96) ~[zipfs.jar:1.8.0_202]
at com.sun.nio.zipfs.ZipFileSystemProvider.newFileSystem(ZipFileSystemProvider.java:110) ~[zipfs.jar:1.8.0_202]
at java.nio.file.FileSystems.newFileSystem(Unknown Source) ~[?:1.8.0_202]
at java.nio.file.FileSystems.newFileSystem(Unknown Source) ~[?:1.8.0_202]
at org.odhsi.utils.cpt.ConceptUpdateService.getPath(ConceptUpdateService.java:107) [cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptUpdateService.getPredefinedReferencesMap(ConceptUpdateService.java:70) [cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptUpdateService.updateCodes(ConceptUpdateService.java:46) [cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptService.process(ConceptService.java:38) [cpt4.jar:?]
at org.odhsi.utils.cpt.Application.main(Application.java:45) [cpt4.jar:?]
[ERROR] 2019-11-03 13:50:24.162 [main] ConceptUpdateService - Cannot retrieve codes from UMLS.
java.lang.IllegalStateException: java.lang.UnsupportedOperationException
at org.odhsi.utils.cpt.ConceptUpdateService.getPath(ConceptUpdateService.java:113) ~[cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptUpdateService.getPredefinedReferencesMap(ConceptUpdateService.java:70) ~[cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptUpdateService.updateCodes(ConceptUpdateService.java:46) [cpt4.jar:?]
at org.odhsi.utils.cpt.ConceptService.process(ConceptService.java:38) [cpt4.jar:?]
at org.odhsi.utils.cpt.Application.main(Application.java:45) [cpt4.jar:?]
Caused by: java.lang.UnsupportedOperationException
at com.sun.nio.zipfs.ZipFileSystemProvider.ensureFile(ZipFileSystemProvider.java:96) ~[zipfs.jar:1.8.0_202]
at com.sun.nio.zipfs.ZipFileSystemProvider.newFileSystem(ZipFileSystemProvider.java:110) ~[zipfs.jar:1.8.0_202]
at java.nio.file.FileSystems.newFileSystem(Unknown Source) ~[?:1.8.0_202]
at java.nio.file.FileSystems.newFileSystem(Unknown Source) ~[?:1.8.0_202]
at org.odhsi.utils.cpt.ConceptUpdateService.getPath(ConceptUpdateService.java:107) ~[cpt4.jar:?]
… 4 more
[ERROR] 2019-11-03 13:50:24.163 [main] Application - Cannot process CONCEPT.csv file. You can find more details in the logs/logfile.log file.
Reason: java.lang.IllegalStateException: java.lang.UnsupportedOperationException

otaka0721,
I did not manage to reproduce this error yet. Can you provide some info:

  • what operating system do you use?
  • how exactly do you run cpt4? the command that you use (of cause without passwords)

I used windows 10 and ran the command “java -Dumls-user=xxx -Dumls-password=xxx -jar cpt4.jar 5” in the command prompt replacing “xxx” with UMLS ID and pass. I placed all the unzipped files in the same directory as cpt4.jar.

Thank you.

otaka0721, I was not able to reproduce the error(I tried different environments and different settings). Let’s compare the steps that we are doing:

  1. unzip the file
  2. Add CONCEPT.csv file in new unzipped directory
  3. run java -Dumls-user=xxx -Dumls-password=xxx -jar cpt4.jar 5
  4. copy updated CONCEPT.csv back in the original directory

It worked successfully! The error seems to be caused by the invalid directory. I placed the files on one drive at first. It goes well when I moved them to the C drive.

Many thanks, for your kind support!

t