Editing
Scanco Administration
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Evaluation FAQ== ===Customize your evaluation script=== The basic procedure is to create your customized evaluation script is: #Clear the database of existing results #Do your evaluation #Extract the results #Paste results into excel template. You could repeat as necessary to evaluate a measurement multiple times and write out the results to a file. *You must submit all jobs to a single queue!!! '''1) Start ipl and clear the database of existing results.''' <pre> $ IPL_BATCH /db_clear_eval -input "IPL_AIM .. </pre> '''2) Insert your IPL evaluation.''' '''3) Extract the results.''' <pre>$@com:extract_results.com P1 P2</pre> *P1 is the aim file (including path) and P2 is the result file (including path) Example: <pre> $@com:extract_results.com DISK5:[BONELAB.PROJECTS.BUIE]MYAIM.AIM DISK5:[BONELAB.PROJECTS.BUIE]MYRESULTS.TXT </pre> *P2 should be the same for all samples in your project so that results are compiled into a single file. '''4) Paste results into excel template.''' *Refer to the [[Media:Extract_Results_Template.xlsx |'''Excel Extract Results Template''']]. *Open your results text file and copy and paste the contents into cell A2. There's no need to use paste special since the sheet is protected. [[Image:Redirect.jpg|15px]] [[#top|''Return to Contents'']] or [[Main_Page|''Return to Main Page'']] ===Create your own IPL script=== To make a script that would submit a job to the queue with the command as follows: <pre> $ @um:ipl_eval_only.com 'aim_file' 'gobj_file' 'p1' 0 </pre> you need to create your own IPL file would be translated to the following command: <pre> $ submit /noprint /que=sys$slow ue:IPL_VOI_JOSH_M.COM - /log=sys$scratch:test.log /para=('aim_file','gobj_file','seg_file') </pre> The IPL file would look something like this… <pre> $ if p1 .EQS. "" $ THEN $ write sys$output "Give DK0:[xxx]C0001234_SEG.aim on the line." $ write sys$output "Or: " $ write sys$output "Type $ scanco_submit_command um:ipl_eval_autostart/para=(dk0:[xxx]c00123_seg.aim) " $ exit $ endif $ $ gobj_file = p1-F$PARSE(p1,,,"VERSION")-"_SEG.AIM" + ".GOBJ" $ aim_file = p1-F$PARSE(p1,,,"VERSION")-"_SEG.AIM" + ".AIM" $ $! $ @um:ipl_eval_only.com 'aim_file' 'gobj_file' 'p1' 0 $ exit </pre> Some more handy IPL sequences are: <pre> $ INPUT = F$SEARCH("UCT_MEASUREMENT_DATA:[*.*''P1']*.RSQ",1) </pre> and then you just need to give meas. number as P1 (and maybe slice range as p2), <pre> $ if p2 .eqs. "" then p2 := A </pre> OR, some nice starts are: <pre> $ IF P3 .EQS. "" $ THEN $ WRITE SYS$OUTPUT "P1: Measurement Number to duplicate" $ WRITE SYS$OUTPUT "P2: New Sample Number from Database" $ WRITE SYS$OUTPUT "P3: New Start Letter of ISQ file" $ WRITE SYS$OUTPUT "P4: Optional: Operator Number" $ WRITE SYS$OUTPUT "P5: Optional: Controlfile Number" $ EXIT $ ENDIF </pre> where you say which parameters HAVE to be there (up to p3), and which ones are optional. All together, the script may look like this: <pre> $ IF P1 .EQS. "" $ THEN $ WRITE SYS$OUTPUT "P1: Measurement Number to reco" $ WRITE SYS$OUTPUT "P2: Optional: Slice number N or Range M:N. Auto:All" $ WRITE SYS$OUTPUT "P3: Optional: Queue. Auto: sys$slow" $ EXIT $ ENDIF $ if p2 .eqs. "" then p2 := A $ if p3 .eqs. "" then p3 := SYS$SLOW $ slices = p2 $ quename = p3 $ INPUT = F$SEARCH("UCT_MEASUREMENT_DATA:[*.*''P1']*.RSQ",1) $ INPUT = INPUT - F$PARSE(INPUT,,,"VERSION") $ logfile = "sys$scratch:RECO_" + f$PARSE(input,,,"NAME") + ".LOG" $ submit/noprint/queue='quename' uct_reconstruction_file - /para=('input','slices','logfile') $ exit </pre> Note that <code>uct_reconstruction_file</code> is a logical that points to <code>um:uct_reconstruction.com</code>. Logicals are preferred in scripts to make them more universal. [[Image:Redirect.jpg|15px]] [[#top|''Return to Contents'']] or [[Main_Page|''Return to Main Page'']] ===Valid and Locked Settings for an eval script=== Each evaluation when running <code>UCT_EVALUATION</code> can be made <code>VALID</code> and <code>LOCKED</code>. :<code>VALID</code>: The evaluation script shows up as an option to execute when running <code>UCT_EVALUATION</code>. When you notice script numbers missing in the list, it is because they have had <code>VALID=0</code> :<code>LOCKED</code>: The evaluation script can be used, but the user cannot make changes to the script settings in <code>UCT_EVALUATION</code>. This is to protect from somebody causing an error in the script settings that affect all users. It is not possible to delete a script, and it is not possible to add a script at an arbitrary script number. So, any newly added script gets the next monotonically increased script number. This can lead to scripts that have similar purposes being spread throughout the list of scripts, which is annoying. It is possible to organize the scripts, although it is a fair amount of work and easy to make a mistake. As a normal user (e.g., 'xtremect2') run the script. If you are a different user you may need to set the correct evalscript database first. The most simple executable to run is <pre> run ut:UCT_UPD_EVALSCR_MISC.EXE <...snip...> * 578 127/563 (ML) Knee Segmentation 579 128/569 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ,NM 580 128/570 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ,NM * 581 128/580 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ,NM 582 129/572 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM 583 129/573 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM * 584 129/574 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM Choose evalscript Record (IDX): [584]: 337 Description [XtremeCT II - Standard Radius Patient Analysis 61µm]: Valid [1]: Locked [1]: Favourite [0]: Category [32]: Save Record ? [Y]: </pre> A more comprehensive executable that allows the user to edit parameters in the script is: <pre> run UT:UCT_UPDATE_EVALSCRIPT.EXE <...snip...> V IDX escript/Rec. Description 1 1/1 XtremeCT Standard Patient Evaluation (RL,RR,TL,TR,CU) 2 1/7 XtremeCT Standard Patient Evaluation (RL,RR,TL,TR,CU) * 3 1/9 XtremeCT Standard Patient Evaluation (RL,RR,TL,TR,CU) 4 2/2 QC1 Trabecular Morphometry 5 2/8 QC1 Trabecular Morphometry 6 2/384 QC1 Trabecular Morphometry * 7 2/401 QC1 Trabecular Morphometry 8 3/3 QC2 9 3/6 QC2 10 3/385 QC2 * 11 3/402 QC2 * 12 4/4 3D Segmentation of VOI, 1 solid objectAIM * 13 5/5 3D Seg. of 2 VOIs: solid dense in transparent low dens obj obj * 14 6/10 Bone Trab. Morphometry (3D Seg, 3D Calc, Print Sheet)et)eet) * 15 7/11 Convert to DICOM 16 8/12 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 17 8/13 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 18 8/14 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 19 8/15 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 20 8/16 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 21 8/17 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 22 8/18 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 23 8/23 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 24 8/24 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 25 8/33 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 26 8/57 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 27 8/58 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 28 8/71 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 29 8/72 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 30 8/79 RESOLUTION, Mimic, Std Pat Eval, copy to UR, submit AutoCont 31 9/19 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 32 9/20 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 33 9/21 RESOLUTION, Standard Pat Eval, copy to UR, submit AutoCont 34 9/22 RESOLUTION, XCT2STD, Std Pat Eval, copy to UR, submit AutoCont <snip> 572 127/559 (ML) Knee Segmentation 573 127/561 (ML) Knee Segmentation * 574 127/563 (ML) Knee Segmentation 575 128/569 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ,NM * 576 128/570 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ,NM 577 129/572 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM 578 129/573 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM * 579 129/574 XtremeCT II - Standard Radius/Tibia Patient Post-processing,NM 580 130/0 New Record Choose evalscript Record (IDX,*=Valid): [579]: </pre> Press Enter many times until you are prompted with <code>Save [Y]</code> The <code>*</code> indicates which scripts are active. You can see there are multiple versions of the same script in many cases. If you want to activate or deactivate a script you must use the IDX number (not the script number). For example, if you want to edit script 128, you select the active IDX, which is 576. Copying script information from one IDX entry to another is a manual process you can do in <code>UCT_EVALUATION</code>. Be careful! [[Image:Redirect.jpg|15px]] [[#top|''Return to Contents'']] or [[Main_Page|''Return to Main Page'']] ===Exporting evaluation script parameters to text=== Nik at Scanco installed a program onto our system, but it is only to be used VERY carefully. <b>Never</b> use the <code>import</code> function, only the <code>export</code> function. It's reading the evalscript database defined by the logical <code>UCT_EVALSCRIPT_DATABASE</code>. The file is usually located at <code>UCTD:UCT_EVALSCRIPTS_*.DAT</code> and is part of the weekly database backup. $ run ut:uct_impexp_evalscripts It will output an interactive session as following: <pre> UCT_IMPEXP_EVALSCRIPTS V1.0 Export (0) or Import (1) [0]: ! 0 for export EXPORT File [SYS$SCRATCH:EVALSCRIPTS.TXT]: ! output file V No IDX/INDEX Description ! list of scripts 1 1/2489 3D Segmentation of VOI, 1 solid object 2 3/862 3D Segmentation of 3 VOIs, concatenation of all 3ionenation of 3 4/608 3D Segmentation of 4 VOIs, concatenation of all 4ionicatenati 4 5/2711 Bone Trab. Morphometry (3D Seg, 3D Calc, Print Sheet) .... 342 460/2945 XtremeCT II - Standard Radius Patient Evaluation 61µm 343 461/2946 XtremeCT II - Autocontour Largest bone (Radius or Tibia) 344 463/2965 NK frequency table, histogram 345 464/2968 Convert to DICOM Export evalscript Record (IDX): [1]: ! enter the number of the eval script to export </pre> To export all scripts, just press <code>Enter</code> through the whole list. To stop, enter number 0. Afterwards check the output file <code>SYS$SCRATCH:EVALSCRIPTS.TXT</code>. Please give it a try and let me know if you have any questions. <b>Interpretation of output</b> There will be records for each entry. Currently there are 76 entries: <pre> ! ! Script 23 ! 594 34 NO PRINT - Patient Analysis 61µm, After manual corr. on GOBJ 1357462144 11358111 1513331376 12153769 1 0 0 !!! Installed on request only !!! �Starts the standard patient analysis (segmentation and evaluation), �after manual correction on _TRAB.GOBJ ; _CORT.GOBJ will be corrected accordingly.�Same script for Radius and Tibia analyses�Send postprocessing to SCSRV1_FAST. No results sent to printer. 0 0 0 0 0 0 0 10UE:UCT_EVALUATION_V6.COM|UE:IPLV6_UPAT_REDO_E5E6_XT2.COM|UE:STARTER_UPAT_POSTPROCESS_NOPRINT.COM 1?|?|+.ISQ|+.AIM|+_SEG.AIM|+_CORT_MASK.GOBJ|+_TRAB_MASK.GOBJ|+_CORT_MASK.AIM|+_TRAB_MASK.AIM|+_CORT_SEG.AIM|+_TRAB_SEG.AIM|+_PORE.AIM|+_TRAB_TH.AIM|+_TRAB_SP.AIM|+_TRAB_1N.AIM|+_CORT_TH.AIM|+_CORT_SP.AIM 26|+.GOBJ|0|+_CORT_MASK.GOBJ|0|+_TRAB_MASK.GOBJ 0 8UPAT_XT2|?|?|?|?|SYS$SCRATCH:|+.LOG|SYS$FAST 40.8|1|450|3000|2|0.8|1|320|3000|2 6AUTO_UPAT_SHEET|0|SYS$PRINT|PS,PDF|1024 0 0 0 0 0 0 0 538976288 538976288 2105376 0.0000000 5.0000000 0 0 3 0.0000000 0.0000000 0 0 3 0.0000000 0.0000000 0 0 3 0.0000000 0.0000000 ! ! </pre> The first number after the line <code>! Script 23</code>, in this case <code>594</code> is the IDX number. The next number <code>34</code> is the position of the script in the list. In the output file, each row is marked with a number. You have to be careful to not interpret the line incorrectly. The single-digit number that precedes the script value has a meaning: 26|+.GOBJ|0|+_CORT_MASK.GOBJ|0|+_TRAB_MASK.GOBJ means type <code>2</code> with script info: <code>6|+.GOBJ|0|+_CORT_MASK.GOBJ|0|+_TRAB_MASK.GOBJ</code> 40.8|1|450|3000|2|0.8|1|320|3000|2 means type <code>4</code> with script info: <code>0.8|1|450|3000|2|0.8|1|320|3000|2</code> [[Image:Redirect.jpg|15px]] [[#top|''Return to Contents'']] or [[Main_Page|''Return to Main Page'']] ===Run Scanco cut and match function (on Percy)=== ;At DATA DISK: Run<code>$ upat_list</code> *mode 1, list mode. *Select patients and site, etc. *Select the appropriate template file, e.g. <code>UE:UPAT_TEMPL_CUTMATCH_AUTO_PATTB_CT.TXT</code> *Output to a file, then run that file. ;At PROJECT DISK: If you have moved the files to the project directory and renamed them, you can generate a script from: <pre> $ @UE:SEARCH_PROJECTS_CUTMATCH.COM -P1 = filename with device and directory -P2 = site (RR, RL, TR, TL) -P3 = output filename </pre> For example, if we run: <pre> $ @UE:SEARCH_PROJECTS_CUTMATCH.COM DISK3:[MICROCT.PROJECTS.GRACE]GRACE_01_00MTH_RR.AIM RR MYFILE.COM </pre> The script will search <code>DISK3:[MICROCT.PROJECTS.GRACE]</code> for files in the form <code>G*RR*.AIM</code> with the same length as <code>GRACE_01_00MTH_RR</code>, then check sample numbers to determine if the file is a follow-up scan. *Upat_list is called to obtain position and dimension data for matching slices. *The output file <code>DISK3:[MICROCT.PROJECTS.GRACE]MYFILE.COM</code> is created to submit and run the cut and match. Before running, open the file and add <code>$ exit</code> at the end. <pre>$ @DISK3:[MICROCT.PROJECTS.GRACE]MYFILE.COM</pre> For multiple files, do something like the following. <pre> $ @UE:SEARCH_PROJECTS_CUTMATCH.COM DISK3:[MICROCT.PROJECTS.GRACE]GRACE_01_00MTH_RR.AIM RR MYFILE.COM $ @UE:SEARCH_PROJECTS_CUTMATCH.COM DISK3:[MICROCT.PROJECTS.GRACE]GRACE_02_00MTH_RR.AIM RR MYFILE.COM </pre> Open MYFILE.COM and add <code>$ exit</code> at the end. <pre>$ @MYFILE.COM</pre> *The script assumes all follow-ups are provided. *If follow-up scans are missing, it will be necessary to modify the output file so that the position and dimension data matches the files or update the <code>SEARCH_PROJECTS_CUTMATCH.COM</code> script. [[Image:Redirect.jpg|15px]] [[#top|''Return to Contents'']] or [[Main_Page|''Return to Main Page'']]
Summary:
Please note that all contributions to bone.wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
BoneWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Log in
associated-pages
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Main page
Documents
Recent changes
Help
Tools
What links here
Related changes
Page information