Engines Home | DATAMINEBLOCKTOCSV
HxGN MinePlan™ 3D Standalone Engines Help v.4.4.4 |
|
Contents:Descriptionregister_datamine_api.batInput FilesOutput FilesCommand Line UsageConfiguration FileUsage ExamplesNotes
DescriptiondatamineBlockToCsv.exe is a command line executable that allows you to convert a Datamine block model file into an ASCII .csv file for use with MSDART. As part of this conversion a number of helper files are output to assist the user in correctly reblocking the model (in the case of sub-blocked models) or importing directly in the case of a simple model. Note: This version of the Datamine model to CSV converter works with non-rotated models only. register_datamine_api.batIf you are unable to run datamineBlockToCsv.exe, the Datamine import library (DmFile.DLL) might not be properly registered on your system. If you have administrative privileges on your computer, you will need to run the batch file register_datamine_api.bat to register the import library. This batch file is found in the %medexe% folder. Input FilesThere are only two input files for using utility: Datamine Block Model file: *.dm, required. This is the file that we are reading and converting Configuration File: *.ini, optional. dmToCsvConfiguration.ini is provided by default. This allows the users to share settings for conversion of their block model files and easily batch this utility. Output FilesThis utility creates several output files to allow for importing to a MineSight block model, provide information about the characteristics of the Datamine block model, and utility files for ease of importing in the case of a simple, non-sub-blocked model. Unless the output file names are specified, their names are generated. If the csv output file is specified, the schema and grade items files will have the same name + appropriate extension. For example if the csv output file is specified as block1.csv, the other output files would be block1.schema and block1.dat. Otherwise, the same naming convention is used but based on the input block model file name. CSV file:*.csv. This file is the comma separated file which contains the data from the block model. Format: xWorld, yWorld, zWorld, xCenter, yCenter, zCenter, xLength, yLength, zLength, Grade items......, blockNum, Volume, extentXMin, extentYMin, extentZMin, extentXMax, extentYMax, extentZMax Grade Items: Grade items are one or more variable columns (custom variables) in the Datamine block model. Numeric Grade Items: these are output as-is with the precision specified as part of the command-line or configuration. By default the precision is 3 decimal places. String Grade Items: string grade items are output as integers for ease of importing into MineSight. The translation tables for string grade items can be found in the schema output file as long as the "-schema" flag was not specified. Schema file:*.schema. This file contains information about the characteristics of the block model. This file is purely informational for the user. Contents:
Grade Items:*.dat. This file contains a list of the grade items present in the csv file and formatted for being input to the MineSight block model. This can be used when initializing model. Format: Truncated variable name min max precision *note: min is represented as a lower bound integer (rounded down) and max is an upper bound integer (rounded up) based on the min and max found in the model. Truncation of Item Names: because this file is intended to be used for importing to File 15, we have a character limit of 5. Names are truncated to 5 characters and upper-cased. If matches are found, these are further truncated and given an index. This may still result in duplicates. It is the user's responsibility to then edit this file. These truncated names can also be found in the schema file. In an attempt to make truncated names conform to the 6bit requirement for MineSight block model files, truncated names are also modified to remove invalid characters. Valid characters are ASCII 32-94. Underscores _ are replaced with a dash -. All other invalid characters are replaced with a ?. Command Line UsagedatamineBlockToCsv.exe - this is the executable name for this utility
Configuration FileA configuration file can be used to configure the datamineBlockToCsv.exe utility. This .ini file is not required as all options are available via the command line. The command line or configuration file must specify the block model to be converted at the bare minimum. A sample configuration file is provided as "dmToCsvConfiguration.ini". *NoteThe configuration file used in conjunction with the command line arguments will overwrite any settings specified in the command line arguments. For example, if in the command line arguments you specify "--precision 6" and in the configuration file you specify "precision=2", the precision will be 2. If on the command line you specify "--precision 6" and in the configuration file you specify "precision=", the precision will remain at 6 because you did not specify a value. [files]
[options]
[precision]
[extents]You can optionally specify a series of min and max values for use in extent filtering. Any combination of these filters can be used and extents can be negative, positive, and zero. If no extent filters are supplied, all blocks will be output to the comma separated file. Extent filters are with respect to model extent values and not world extent values.
Example Configuration File:Usage Examples:datamineBlockToCsv.exe -bmfin someBlockModel.dm
datamineBlockToCsv.exe –s -bmfin someBlockModel.dm
datamineBlockToCsv.exe –o -bmfin someBlockModel.dm -csvout filteredModel.csv -confin dmToCsvConfiguration.ini
Notes
|