hm_comparereadfile
Reads comparison data from a file into the comparison database.
Syntax
hm_comparereadfile filename overwrite
Type
HyperMesh Tcl Query
Description
Reads comparison data (transformations, match types, match entities, etc...) from a file into the comparison database. This must be preceded by a call to hm_compareinit.
This is useful for large comparisons that take a lot of time to generate. The data can be saved to a file and reloaded in a new session to save time.
Inputs
- filename
- The full name and path of the file to read the data from.
- overwrite
- 0 - Do not overwrite existing comparison results
Example
To write the comparison data file to C:/temp/my_compare.txt for the same side comparison of surfs 1-20 and 101-120:
*createmark surfs 1 1-20
*createmark surfs 2 101-120
hm_compareinit
hm_compareentitiessameside surfs 1 surfs 2 0.1 2 0
hm_comparewritefile C:/temp/my_compare.txt
hm_compareend
To read the comparison data file from C:/temp/my_compare.txt and review the distances:
hm_compareinit
hm_comparereadfile C:/temp/my_compare.txt 1
hm_comparefinddistances 1.0 1
hm_comparesetreview 2
hm_compareend
Errors
if { [ catch {command_name...} ] } {
# Handle error
}
Version History
12.0