You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Overview

Information on the ICD10CM mapping project.

  • ModuleId: 
  • RefsetId: 6011000124106

Helpful Admin Commands

Setting up new ICD10CM Mapping Project

Load ICD10CM

Load icd10cm_2016.xml to /home/ihtsdo/data/ICD10CM
Change owner of icd10cm_2016.xml to root
Load icd10cm data
cd /opt/mapping-service-admin/admin/loader
mvn clean install -PClaML -Drun.config=/opt/mapping-service/conf/config.properties -Dinput.file=/home/ihtsdo/data/ICD10CM/icd10cm-2016.xml -Dterminology=ICD10CM -Dversion=2016

Load SNOMEDCT_US

Pre-process the map file to clean up map relations  (see code below - examples 109006, 2217001, 2268003)

cd /opt/mapping-service-admin/admin/loader
make sure complex_map_refset_members table mapRule field is type longtext, not varchar(255)
make sure enough memory is provided (consider ~/.bash_profile): export MAVEN_OPTS="-XX:MaxPermSize=512m -Xmx3300M"
mvn clean install -PRF2-snapshot -Drun.config=/opt/mapping-service/conf/config.properties -Dinput.dir=/home/ihtsdo/data/SNOMEDCT_US/SnomedCT_USEditionRF2_Production_20170301T120000/Snapshot -Dterminology=SNOMEDCT_US -Dversion=latest

Make SNOMEDCT_US to ICD10CM project logged in as Administrator
Confirm refsetId by looking for mapping in the Terminology/..descriptions.. file in the SNOMEDCT_US release files refsetId (6011000124106)

Load Map Records from RF2
cd /opt/mapping-service-admin/admin/loader
set file = /home/ihtsdo/data/SNOMEDCT_US/SnomedCT_USEditionRF2_Production_20170301T120000/Snapshot/Refset/Map/der2_iisssccRefset_ExtendedMapSnapshot_US1000124_20170301.txt
perl -ne '@_=split/\t/; print if $_[4] eq "6011000124106"' $file > /tmp/x.txt
mvn install -PMapRecords -Drun.config=/opt/mapping-service/conf/config.properties -Dinput.file=/tmp/x.txt -Dmember.flag=false -Drecord.flag=true

Compute workflow
cd /opt/mapping-service-admin/admin/loader
mvn install -PComputeWorkflow -Drun.config=/opt/mapping-service/conf/config.properties -Drefset.id=6011000124106

Add advices, map relations, users

 

<code>

$ cat x.pl
#!/usr/bin/perl

$mapPriority = 1;
while(<>) {
@_=split/\t/;

$key = "$_[5]$_[6]";
if ($prevkey ne $key) {
$mapPriority = 1;
} else {
$mapPriority++;
}

if ($_[8] =~ /^IFA/) {
if ($_[8] !~ /^IFA 248153007/ &&
$_[8] !~ /^IFA 248152002/ &&
$_[8] !~ /^IFA 445518008/) {
next;
}
}

$_[7] = $mapPriority;
if ($_[8] =~ /OTHERWISE TRUE/ && $mapPriority == 1) {
$_[8] =~ s/OTHERWISE //;
}

print join "\t", @_;

$prevkey = "$_[5]$_[6]";
}
chmod 775 ./x.pl
cat x | ./x.pl > new.map.file.for.loading.txt

</code>