GXMULTIGRID3DUTIL class

class GXMULTIGRID3DUTIL(handle=0)[source]

GXMULTIGRID3DUTIL class.

High Performance 3D Grid.

__init__(handle=0)[source]

Initialize self. See help(type(self)) for accurate signature.

classmethod check_equal_to_legacy_voxel(grid3d_file, legacy_grid3d_file)[source]

Compare GXMULTIGRID3D to Legacy Voxel

Parameters
  • grid3d_file (str) – Voxel file

  • legacy_grid3d_file (str) – Legacy Voxel file

New in version 9.4.

License: Geosoft Open License

classmethod clip_to_polygon(input_file, output_file, poly, clip_dummies)[source]

Invert the Z values in the Grid3d.

Parameters
  • input_file (str) – Name of the input grid3d

  • output_file (str) – Name of the output grid3d

  • poly (GXPLY) – Polygons to clip to

  • clip_dummies (int) – Clip Dummies (1) or leave them (0)

New in version 9.5.

License: Geosoft End-User License

classmethod compute_default_cell_size(min_x, max_x, min_y, max_y, min_z, max_z)[source]

Used if the user does not provide a default cell size.

Parameters
  • min_x (float) – MinX

  • max_x (float) – MaxX

  • min_y (float) – MinY

  • max_y (float) – MaxY

  • min_z (float) – MinZ

  • max_z (float) – MaxZ

Returns

Default Cell Size

Return type

float

New in version 9.4.

License: Geosoft End-User License

Note: Compute a default cell size for a grid3d given a data range.

classmethod convert_density_to_velocity(input_grid3d_filename, input_scaling_factor, input_lower_bound, input_upper_bound, a5, a4, a3, a2, a1, a0, output_scaling_factor, output_grid3d_filename)[source]

Convert Density MultiVoxset to Velocity MultiVoxset

Parameters
  • input_grid3d_filename (str) – Input grid3d filename

  • input_scaling_factor (float) – 1.0, if this grid3d is in meters per second. Otherwise, a value by which each input cell is multiplied to convert it into meters per second.

  • input_lower_bound (float) – Lower bound on velocity values, in meters per second. If the input value (after being pre-multiplied by dInputScalingFactor) is less than this value, the output cell value will be DUMMY.

  • input_upper_bound (float) – Upper bound on velocity values, in meters per second. If the input value (after being pre-multiplied by dInputScalingFactor) is greater than this value, the output cell value will be DUMMY.

  • a5 (float) – Coefficient of fifth-order polynomial term.

  • a4 (float) – Coefficient of fourth-order polynomial term.

  • a3 (float) – Coefficient of third-order polynomial term.

  • a2 (float) – Coefficient of second-order polynomial term.

  • a1 (float) – Coefficient of first-order polynomial term.

  • a0 (float) – Constant offset of output.

  • output_scaling_factor (float) – 1.0, to produce an output grid3d that has units of g/cm^3. If different units are desired, pass in a different value, which will be multiplied into each output grid3d cell.

  • output_grid3d_filename (str) – Output grid3d filename

New in version 9.4.

License: Geosoft Open License

classmethod convert_double_to_thematic(input_grid3d_filename, translate_vv, tpat, output_grid3d_filename)[source]

Convert Double MultiVoxset to Thematic MultiVoxset

Parameters
  • input_grid3d_filename (str) – Input grid3d filename

  • translate_vv (GXVV) – Translation VV handle

  • tpat (GXTPAT) – GXTPAT object

  • output_grid3d_filename (str) – Output grid3d filename

New in version 9.4.

License: Geosoft Open License

classmethod convert_double_to_vector(x_file_name, y_file_name, z_file_name, out_file_name, inclination, declination, rotated)[source]

Convert 3 Double Voxels to a Vector Voxel

Parameters
  • x_file_name (str) – Input X Voxel file

  • y_file_name (str) – Input Y Voxel file

  • z_file_name (str) – Input Z Voxel file

  • out_file_name (str) – Output Vector Voxel file

  • inclination (float) – Inclination

  • declination (float) – Declination

  • rotated (bool) – Rotated?

New in version 9.4.

License: Geosoft Open License

classmethod convert_thematic_to_double(input_grid3d_filename, translate_vv, output_grid3d_filename)[source]

Convert Thematic MultiVoxset to Double MultiVoxset

Parameters
  • input_grid3d_filename (str) – Input grid3d filename

  • translate_vv (GXVV) – Translation VV handle

  • output_grid3d_filename (str) – Output grid3d filename

New in version 9.4.

License: Geosoft Open License

classmethod convert_vector_to_double(file_name, x_file_name, y_file_name, z_file_name, rotated)[source]

Convert a Vector Voxel to 3 double Voxels

Parameters
  • file_name (str) – Input Vector Voxel file

  • x_file_name (str) – Output X Voxel file

  • y_file_name (str) – Output Y Voxel file

  • z_file_name (str) – Output Z Voxel file

  • rotated (bool) – Rotated?

New in version 9.4.

License: Geosoft Open License

classmethod convert_vector_to_double_using_rotation(file_name, x_file_name, y_file_name, z_file_name, inclination, declination)[source]

Convert a Vector Voxel to 3 double Voxels using an external rotation. Internal rotations are ignored.

Parameters
  • file_name (str) – Input Vector Voxel file

  • x_file_name (str) – Output X Voxel file

  • y_file_name (str) – Output Y Voxel file

  • z_file_name (str) – Output Z Voxel file

  • inclination (float) – Inclination

  • declination (float) – Declination

New in version 9.5.

License: Geosoft Open License

classmethod convert_velocity_to_density(input_grid3d_filename, input_scaling_factor, input_lower_bound, input_upper_bound, a5, a4, a3, a2, a1, a0, output_scaling_factor, output_grid3d_filename)[source]

Convert Velocity MultiVoxset to Density MultiVoxset

Parameters
  • input_grid3d_filename (str) – Input grid3d filename

  • input_scaling_factor (float) – 1.0, if this grid3d is in meters per second. Otherwise, a value by which each input cell is multiplied to convert it into meters per second.

  • input_lower_bound (float) – Lower bound on velocity values, in meters per second. If the input value (after being pre-multiplied by dInputScalingFactor) is less than this value, the output cell value will be DUMMY.

  • input_upper_bound (float) – Upper bound on velocity values, in meters per second. If the input value (after being pre-multiplied by dInputScalingFactor) is greater than this value, the output cell value will be DUMMY.

  • a5 (float) – Coefficient of fifth-order polynomial term.

  • a4 (float) – Coefficient of fourth-order polynomial term.

  • a3 (float) – Coefficient of third-order polynomial term.

  • a2 (float) – Coefficient of second-order polynomial term.

  • a1 (float) – Coefficient of first-order polynomial term.

  • a0 (float) – Constant offset of output.

  • output_scaling_factor (float) – 1.0, to produce an output grid3d that has units of g/cm^3. If different units are desired, pass in a different value, which will be multiplied into each output grid3d cell.

  • output_grid3d_filename (str) – Output grid3d filename

New in version 9.4.

License: Geosoft Open License

classmethod create_double_constant(name, value, ox, oy, oz, cell_x, cell_y, cell_z, size_x, size_y, size_z, ipj)[source]

Generate a double MultiVoxset with a constant value

Parameters
  • name (str) – Name of output Voxel File

  • value (float) – Constant Value to use - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cell_x (float) – Cell Size X

  • cell_y (float) – Cell Size Y

  • cell_z (float) – Cell Size Z

  • size_x (int) – Cell Count X

  • size_y (int) – Cell Count Y

  • size_z (int) – Cell Count Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod create_double_constant_copy(name, value, source_name)[source]

Generate a double MultiVoxset with a constant value based on an input voxel

Parameters
  • name (str) – Name of output Voxel File

  • value (float) – Constant Value to use - DUMMY for a trully sparse grid3d

  • source_name (str) – Name of voxel to model

New in version 9.5.

License: Geosoft Open License

classmethod create_double_constant_vv(name, value, ox, oy, oz, cx, cy, cz, ipj)[source]

Generate a double MultiVoxset with a constant value and non-uniform cell sizes

Parameters
  • name (str) – Name of output Voxel

  • value (float) – The contant Value to fill with - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cx (GXVV) – Cell Sizes X

  • cy (GXVV) – Cell Sizes Y

  • cz (GXVV) – Cell Sizes Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod create_subset(input_name, output_name, offset_x, offset_y, offset_z, length_x, length_y, length_z)[source]

Create a new MULTIGRID3D that is a subset of an exisiting MULTIGRID3D.

Parameters
  • input_name (str) – File Name of the MULTIGRID3D that will be subset

  • output_name (str) – File Name of the MULTIGRID3D that will be created

  • offset_x (int) – Starting location in X.

  • offset_y (int) – Starting location in Y.

  • offset_z (int) – Starting location in Z.

  • length_x (int) – Number of items to copy in X.

  • length_y (int) – Number of items to copy in Y.

  • length_z (int) – Number of items to copy in Z.

Return type

GXMULTIGRID3D

New in version 9.5.

License: Geosoft Open License

Note: Creates a GXMULTIGRID3D object that is a subset .

classmethod create_subset_from_double_extents(input_name, output_name)[source]

Create a new MULTIGRID3D that is a subset of the non-dummy extents.

Parameters
  • input_name (str) – File Name of the MULTIGRID3D that will be subset

  • output_name (str) – File Name of the MULTIGRID3D that will be created

Return type

GXMULTIGRID3D

New in version 9.5.

License: Geosoft Open License

Note: Creates a GXMULTIGRID3D object that is a subset with all dummy data regions removed.

classmethod create_thematic_constant(name, value, ox, oy, oz, cell_x, cell_y, cell_z, size_x, size_y, size_z, ipj)[source]

Generate a double MultiVoxset with a constant value

Parameters
  • name (str) – Name of output Voxel File

  • value (int) – Constant Value to use - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cell_x (float) – Cell Size X

  • cell_y (float) – Cell Size Y

  • cell_z (float) – Cell Size Z

  • size_x (int) – Cell Count X

  • size_y (int) – Cell Count Y

  • size_z (int) – Cell Count Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod create_thematic_constant_vv(name, value, ox, oy, oz, cx, cy, cz, ipj)[source]

Generate a double MultiVoxset with a constant value and non-uniform cell sizes

Parameters
  • name (str) – Name of output Voxel

  • value (int) – The contant Value to fill with - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cx (GXVV) – Cell Sizes X

  • cy (GXVV) – Cell Sizes Y

  • cz (GXVV) – Cell Sizes Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod create_vector_constant(name, value_x, value_y, value_z, ox, oy, oz, cell_x, cell_y, cell_z, size_x, size_y, size_z, ipj)[source]

Generate a double MultiVoxset with a constant value

Parameters
  • name (str) – Name of output Voxel File

  • value_x (float) – X Constant Value to use - DUMMY for a trully sparse grid3d

  • value_y (float) – Y Constant Value to use - DUMMY for a trully sparse grid3d

  • value_z (float) – Z Constant Value to use - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cell_x (float) – Cell Size X

  • cell_y (float) – Cell Size Y

  • cell_z (float) – Cell Size Z

  • size_x (int) – Cell Count X

  • size_y (int) – Cell Count Y

  • size_z (int) – Cell Count Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod create_vector_constant_vv(name, x_value, y_value, z_value, ox, oy, oz, cx, cy, cz, ipj)[source]

Generate a double MultiVoxset with a constant value and non-uniform cell sizes

Parameters
  • name (str) – Name of output Voxel

  • x_value (float) – The X contant Value to fill with - DUMMY for a trully sparse grid3d

  • y_value (float) – The Y contant Value to fill with - DUMMY for a trully sparse grid3d

  • z_value (float) – The Z contant Value to fill with - DUMMY for a trully sparse grid3d

  • ox (float) – Origin X

  • oy (float) – Origin Y

  • oz (float) – Origin Z

  • cx (GXVV) – Cell Sizes X

  • cy (GXVV) – Cell Sizes Y

  • cz (GXVV) – Cell Sizes Z

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod database_contains_voxel_geometry(db)[source]

Returns 1 if the original voxel geometry is stored inside the database

Parameters

db (GXDB) – GXDB To import from

Return type

int

New in version 2021.1.

License: Geosoft Open License

classmethod export_to_binary(grid3d_file, binary_file, dir, rev_x, rev_y, rev_z, swap, output_type)[source]

Export contents of GXMULTIGRID3D to a Binary File.

Parameters
  • grid3d_file (str) – Input Voxel file

  • binary_file (str) – Binary file to write to

  • dir (int) – DIRECTION3D constants

  • rev_x (bool) – Reverse X?

  • rev_y (bool) – Reverse Y?

  • rev_z (bool) – Reverse Z?

  • swap (bool) – Swap Bytes?

  • output_type (int) – Output Type (Geosoft Type)

New in version 9.4.

License: Geosoft End-User License

classmethod export_to_binary_ex(grid3d_file, binary_file, dir, rev_x, rev_y, rev_z, swap, dummy, output_type)[source]

Export contents of GXMULTIGRID3D to a Binary File, with dummy replacement.

Parameters
  • grid3d_file (str) – Input Voxel file

  • binary_file (str) – Binary file to write to

  • dir (int) – DIRECTION3D constants

  • rev_x (bool) – Reverse X?

  • rev_y (bool) – Reverse Y?

  • rev_z (bool) – Reverse Z?

  • swap (bool) – Swap Bytes?

  • dummy (float) – Replace dummy values with this value on export

  • output_type (int) – Output Type (Geosoft Type)

New in version 9.7.

License: Geosoft End-User License

classmethod export_to_gdb(grid3d_file, db, chan, dir, rev_x, rev_y, rev_z, dummies)[source]

Export To GDB

Parameters
  • grid3d_file (str) – Input Voxel file

  • db (GXDB) – Database

  • chan (str) – Channel Name

  • dir (int) – DIRECTION3D constants

  • rev_x (bool) – Reverse X?

  • rev_y (bool) – Reverse Y?

  • rev_z (bool) – Reverse Z?

  • dummies (bool) – Write Dummies?

New in version 9.4.

License: Geosoft Open License

classmethod export_to_segy(multigrid3d_file, output_segy_filename, sample_interval)[source]

Export To SEGY

Parameters
  • multigrid3d_file (str) – Input Voxel file

  • output_segy_filename (str) – Output Segy file

  • sample_interval (float) – Sampling Internal

New in version 9.4.

License: Geosoft Open License

classmethod export_to_voxel(project_file, multi_voxset_uuid, multi_voxset_attribute, grid3d_file)[source]

Exports a Multi-Voxset into a Voxel

Parameters
  • project_file (str) – Project file

  • multi_voxset_uuid (str) – Multi-Voxset UUID

  • multi_voxset_attribute (str) – Multi-Voxset attribute

  • grid3d_file (str) – Output Voxel file

New in version 9.4.

License: Geosoft Open License

classmethod export_to_wa(file_name, wa, dir, rev_x, rev_y, rev_z, dummy)[source]

Export To GDB

Parameters
  • file_name (str) – Input Voxel file

  • wa (GXWA) – GXWA File

  • dir (int) – DIRECTION3D constants

  • rev_x (bool) – Reverse X?

  • rev_y (bool) – Reverse Y?

  • rev_z (bool) – Reverse Z?

  • dummy (str) – The Dummy string to write

New in version 9.4.

License: Geosoft Open License

classmethod export_to_xml(grid3d_file, xml_file)[source]

Export a GXMULTIGRID3D to XML

Parameters
  • grid3d_file (str) – Voxel file

  • xml_file (str) – XML file

New in version 9.4.

License: Geosoft Open License

classmethod export_to_xyz(grid3d_file, xyz, dir, rev_x, rev_y, rev_z, dummies)[source]

Export a GXMULTIGRID3D to an XYZ File

Parameters
  • grid3d_file (str) – Input Voxel file

  • xyz (str) – File Name

  • dir (int) – DIRECTION3D constants

  • rev_x (bool) – Reverse X?

  • rev_y (bool) – Reverse Y?

  • rev_z (bool) – Reverse Z?

  • dummies (bool) – Write Dummies?

New in version 9.4.

License: Geosoft Open License

classmethod extract_dem(input_file, output_file)[source]

Extract a DEM grid from a voxel.

Parameters
  • input_file (str) – Name of the input grid3d

  • output_file (str) – Name of the output grid

New in version 9.5.

License: Geosoft End-User License

classmethod filter(input_file, output_file, filter, filter_file, n_passes, interpolate_dummies)[source]

Apply a 3D filter to a grid3d.

Parameters
  • input_file (str) – Name of the input grid3d

  • output_file (str) – Name of the output grid3d

  • filter (int) – FILTER3D constants

  • filter_file (str) – Filter file, if filter is VOX_FILTER3D_FILE

  • n_passes (int) – Number of filter passes

  • interpolate_dummies (int) – (1: interpolate dummies)

New in version 9.4.

License: Geosoft End-User License

classmethod get_data_extents(filename, min_x, min_y, min_z, max_x, max_y, max_z)[source]

Get the voxel size that has non-dummy data.

Parameters
  • filename (str) – input filename

  • min_x (int_ref) – Index of minimum valid data in X.

  • min_y (int_ref) – Index of minimum valid data in Y.

  • min_z (int_ref) – Index of minimum valid data in Z.

  • max_x (int_ref) – Index of maximum valid data in X.

  • max_y (int_ref) – Index of maximum valid data in Y.

  • max_z (int_ref) – Index of maximum valid data in Z.

New in version 9.5.

License: Geosoft Open License

Note: Find the non-dummy volume of a GXMULTIGRID3D object. If the voxel is all dummies, returns iMAX for the minima, and iMIN for the maxima.

classmethod get_data_ground_extents(filename, min_x, min_y, min_z, max_x, max_y, max_z)[source]

Get the voxel size in ground units that has non-dummy data.

Parameters
  • filename (str) – input filename

  • min_x (float_ref) – Ground location of minimum valid data in X.

  • min_y (float_ref) – Ground location of minimum valid data in Y.

  • min_z (float_ref) – Ground location of minimum valid data in Z.

  • max_x (float_ref) – Ground location of maximum valid data in X.

  • max_y (float_ref) – Ground location of maximum valid data in Y.

  • max_z (float_ref) – Ground location of maximum valid data in Z.

New in version 9.5.

License: Geosoft Open License

Note: Find the non-dummy volume of a GXMULTIGRID3D object. If the voxel is all dummies, returns iMAX for the minima, and iMIN for the maxima.

classmethod get_gocad_location(input_grid3d_filename, origin_x, origin_y, origin_z, vect_xx, vect_xy, vect_xz, vect_yx, vect_yy, vect_yz, vect_zx, vect_zy, vect_zz)[source]

Get the location of a grid3d with origin and scaled xyz vectors for use with GOCAD.

Parameters

New in version 9.4.

License: Geosoft Open License

classmethod grid_direct_from_gdb(output_grid3d_filename, origin_x, origin_y, origin_z, cell_count_x, cell_count_y, cell_count_z, cell_size_x, cell_size_y, cell_size_z, method, db, x_channel, y_channel, z_channel, data_channel)[source]

Create a grid3d using direct gridding.

Parameters
  • output_grid3d_filename (str) – Output grid3d filename

  • origin_x (float) – Voxel origin X

  • origin_y (float) – Voxel origin Y

  • origin_z (float) – Voxel origin Z

  • cell_count_x (int) – Voxel cell count X

  • cell_count_y (int) – Voxel cell count Y

  • cell_count_z (int) – Voxel cell count Z

  • cell_size_x (float) – Voxel cell size X

  • cell_size_y (float) – Voxel cell size Y

  • cell_size_z (float) – Voxel cell size Z

  • method (int) – MULTIGRID3D_DIRECTGRID_METHOD constants

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

New in version 9.4.

License: Geosoft End-User License

Note: The Z and Data channels may be array channels. If they are, the array sizes must match.

classmethod grid_idw_from_gdb(output_grid3d_filename, origin_x, origin_y, origin_z, cell_count_x, cell_count_y, cell_count_z, cell_size_x, cell_size_y, cell_size_z, db, x_channel, y_channel, z_channel, data_channel, weight_power, weight_slope, search_radius, blanking_distance, log, log_base, log_negative)[source]

Create a grid3d using IDW gridding.

Parameters
  • output_grid3d_filename (str) – Output grid3d filename

  • origin_x (float) – Voxel origin X

  • origin_y (float) – Voxel origin Y

  • origin_z (float) – Voxel origin Z

  • cell_count_x (int) – Voxel cell count X

  • cell_count_y (int) – Voxel cell count Y

  • cell_count_z (int) – Voxel cell count Z

  • cell_size_x (float) – Voxel cell size X

  • cell_size_y (float) – Voxel cell size Y

  • cell_size_z (float) – Voxel cell size Z

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

  • weight_power (float) – Weight Power (default 2)

  • weight_slope (float) – Weight Slope (default 1)

  • search_radius (float) – Distance weighting limit (default = 4 * CUBE_ROOT(DX*DY*DZ))

  • blanking_distance (float) – Dummy values farther from data than this distance. (default = 4 * CUBE_ROOT(DX*DY*DZ))

  • log (int) – Apply log transform to input data before gridding (0:No (default), 1:Yes)

  • log_base (float) – One of VV_LOG_BASE_10 (default) or :const:`VV_LOG_BASE_E

  • log_negative (int) – One of VV_LOG_NEGATIVE_NO (default) or VV_LOG_NEGATIVE_YES

New in version 9.5.

License: Geosoft End-User License

Note: The Z and Data channels may be array channels. If they are, the array sizes must match.

3D cells take on the averaged values within a search radius, weighted inversely by distance.

Weighting can be controlled using the power and slope properties;

weighting = 1 / (distance^wtpower + 1/slope) where distance is in units of grid cells (X dimenstion). Default is 0.0,

If the blanking distance is set, all cells whose center point is not within the blanking distance of at least one data point are set to dummy.

classmethod grid_points_from_gdb(name, error, cell_size, var_only, min_radius, max_radius, min_points, max_points, model, power, slope, range, nugget, sill, type, db, x_channel, y_channel, z_channel, data_channel, ipj)[source]

Grid a grid3d from a database using kriging.

Parameters
  • name (str) – Output grid3d filename

  • error (str) – Output error grid3d filename

  • cell_size (float) – Cell size (DUMMY for default)

  • var_only (int) – Variogram Only

  • min_radius (float) – Minimum Search Radius (DUMMY for none)

  • max_radius (float) – Maximum Search Radius (DUMMY for none)

  • min_points (int) – Minimum Search Points

  • max_points (int) – Maximum Search Points

  • model (int) – Model number 1-power, 2-sperical, 3-gaussian, 4-exponential

  • power (float) – Power

  • slope (float) – Slope

  • range (float) – Range

  • nugget (float) – Nugget

  • sill (float) – Sill

  • type (int) – GS_TYPES constants

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

New in version 9.5.

License: Geosoft Open License

classmethod grid_points_z_ex_from_gdb(name, error, cell_size, cell_size_z, var_only, min_radius, max_radius, min_points, max_points, model, power, slope, range, nugget, sill, strike, dip, plunge, along_strike_weight, down_dip_weight, type, db, x_channel, y_channel, z_channel, data_channel, ipj)[source]

Grid a grid3d from a database (using variable Z’s)

Parameters
  • name (str) – Output grid3d filename

  • error (str) – Output error grid3d filename

  • cell_size (float) – Cell size (DUMMY for default)

  • cell_size_z (str) – Cell size in Z (“” for default)

  • var_only (int) – Variogram Only

  • min_radius (float) – Minimum Search Radius (DUMMY for none)

  • max_radius (float) – Maximum Search Radius (DUMMY for none)

  • min_points (int) – Minimum Search Points

  • max_points (int) – Maximum Search Points

  • model (int) – Model number 1-power, 2-sperical, 3-gaussian, 4-exponential

  • power (float) – Power

  • slope (float_ref) – Slope

  • range (float_ref) – Range

  • nugget (float) – Nugget

  • sill (float_ref) – Sill

  • strike (float) – Strike

  • dip (float) – Dip

  • plunge (float) – Plunge

  • along_strike_weight (float) – Strike Weight

  • down_dip_weight (float) – Dip Plane Weight

  • type (int) – GS_TYPES constants

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

New in version 9.5.

License: Geosoft Open License

classmethod grid_points_z_from_gdb(name, error, cell_size, cell_size_z, var_only, min_radius, max_radius, min_points, max_points, model, power, slope, range, nugget, sill, type, db, x_channel, y_channel, z_channel, data_channel, ipj)[source]

Grid a grid3d from a database (using variable Z’s)

Parameters
  • name (str) – Output grid3d filename

  • error (str) – Output error grid3d filename

  • cell_size (float) – Cell size (DUMMY for default)

  • cell_size_z (str) – Cell size in Z (“” for default)

  • var_only (int) – Variogram Only

  • min_radius (float) – Minimum Search Radius (DUMMY for none)

  • max_radius (float) – Maximum Search Radius (DUMMY for none)

  • min_points (int) – Minimum Search Points

  • max_points (int) – Maximum Search Points

  • model (int) – Model number 1-power, 2-sperical, 3-gaussian, 4-exponential

  • power (float) – Power

  • slope (float) – Slope

  • range (float) – Range

  • nugget (float) – Nugget

  • sill (float) – Sill

  • type (int) – GS_TYPES constants

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

New in version 9.5.

License: Geosoft Open License

classmethod import_from_datamine(file, field, ipj, grid3d)[source]

Create a Geosoft Voxel file from a Datamine block model file.

Parameters
  • file (str) – Datamine file name

  • field (str) – Field to use for data

  • ipj (GXIPJ) – Projection to set

  • grid3d (str) – Output grid3d file name

New in version 9.4.

License: Geosoft End-User License

Note: Create a Geosoft Voxel file from a Datamine block model file.

classmethod import_from_gdb(grid3d_file, db, symb)[source]

Imports from a Geosoft Database

Parameters
  • grid3d_file (str) – Name of output Voxel file

  • db (GXDB) – GXDB To import from

  • symb (int) – Symbol to import data from

New in version 9.4.

License: Geosoft Open License

classmethod import_from_gdb_ignore_stored_voxel_geometry(grid3d_file, db, symb)[source]

Imports from a Geosoft Database, but ignores any stored internal geometry

Parameters
  • grid3d_file (str) – Name of output Voxel file

  • db (GXDB) – GXDB To import from

  • symb (int) – Symbol to import data from

New in version 2021.1.

License: Geosoft Open License

classmethod import_from_gocad(name, header, property, ipj, orientation)[source]

Imports a MultiVoxset from a GOCAD File

Parameters
  • name (str) – Name of output GXVOX

  • header (str) – Name of GOCAD Voxel file

  • property (str) – Propert name to import

  • orientation (int) – GOCAD_ORIENTATION constants OBSOLETE as of 9.7. The UVW axes and ZPOSITIVE values are read from the *.vo header and are handled on import automatically. By default ZPOSITIVE Elevation is assumed

New in version 9.4.

License: Geosoft Open License

classmethod import_from_ubc(name, mesh, mod, dummy, ipj)[source]

Import UBC file into a MultiVoxset

Parameters
  • name (str) – Name of output GXVOX

  • mesh (str) – Name of UBC Mesh File

  • mod (str) – Name of UBC Mod File

  • dummy (float) – Dummy Value

  • ipj (GXIPJ) – Projection

New in version 9.4.

License: Geosoft Open License

classmethod import_from_vector_gdb(grid3d_file, db, vector_type, symb_x, symb_y, symb_z, inc, dec)[source]

Imports from a Vector Geosoft Database

Parameters
  • grid3d_file (str) – Voxel Name

  • db (GXDB) – GXDB To import from

  • vector_type (int) – VECTOR_IMPORTImport XYZ, UVW or Amplitude/Inclination/Declination channels

  • symb_x (int) – Symbol to import X, U or Amplitude data from

  • symb_y (int) – Symbol to import Y, V or Inclination data from

  • symb_z (int) – Symbol to import Z, W or Declination data from

  • inc (float) – Inclination value for VOX_VECTORVOX_UVW (-90° to 90°)

  • dec (float) – Declination value for VOX_VECTORVOX_UVW (-180° to 180°)

New in version 9.4.

License: Geosoft Open License

classmethod import_from_voxel(project_file, grid3d_file, multi_voxset_attribute, p_uuid_string)[source]

Import a Voxel directly into a Multi-Voxset

Parameters
  • project_file (str) – Project file

  • grid3d_file (str) – Input Voxel file

  • multi_voxset_attribute (str) – Multi-Voxset attribute

  • p_uuid_string (str_ref) – UUID string returned

New in version 9.4.

License: Geosoft Open License

classmethod import_from_xyz(name, ra, type, ipj)[source]

Import XYZ file into a Multi-Voxset

Parameters

New in version 9.4.

License: Geosoft Open License

classmethod invert_z(input_file, output_file)[source]

Invert the Z values in the Grid3d.

Parameters
  • input_file (str) – Name of the input grid3d

  • output_file (str) – Name of the output grid3d

New in version 9.5.

License: Geosoft End-User License

is_null()[source]

Check if this is a null (undefined) instance

Returns

True if this is a null (undefined) instance, False otherwise.

Return type

bool

classmethod krig_from_gdb(name, cell_size, type, db, x_channel, y_channel, z_channel, data_channel, ipj, reg)[source]

A more compact and extensible form of log_grid_points_z_ex_from_gdb.

Parameters

New in version 9.5.

License: Geosoft Open License

Note: Optional Parameters.

If these values are not set in the GXREG, then default parameters will be used.

ERROR_VOXEL: Output error grid3d filename (“” for none) CELLSIZEZ: Z Cell size string (space delimited, “” for default) RADIUS_MIN: Minimum Search Radius (REAL) (Default = 4) (Blanking Distance) RADIUS_MAX: Maximum Search Radius (REAL) (Default = 16) SEARCH_MIN: Minimum Search Points (INT) (Default = 16) SEARCH_MAX: Maximum Search Points (INT) (Default = 32) VARIOGRAM_ONLY: Set to 1 to calculate the variogram only (INT) (Default = 0) MODEL: Variogram Model number 1-power, 2-sperical, 3-gaussian, 4-exponential (INT) (Default = 2) POWER: Power (Default = DUMMY) SLOPE: Slope (REAL) (if input is DUMMY, value calculated and set on return) RANGE: Range (REAL) (if input is DUMMY, value calculated and set on return) SILL : Sill (REAL) (if input is DUMMY, value calculated and set on return) STRIKE: Strike (REAL) (Default = 0) DIP: Dip (REAL) (Default = 90) PLUNGE: Plunge (REAL) (Default = 0) STRIKE WEIGHT: Along-Strike Weight (REAL) (Default = 1) DIP_WEIGHT: Down-Dip Weight (REAL) (Default = 1) LOG_OPT: One of VOX_GRID_LOGOPT constants (Default = 0) MIN_LOG: Log Minimum (REAL) (Default = 1) MIN_X: Minimum X (REAL) (default = DUMMY to determine from the data. If input, nearest lt. or eq. multiple of cell size chosen) MAX_X: Maximum X (REAL) (default = DUMMY to determine from the data. If input, nearest gt. or eq. multiple of cell size chosen) MIN_Y: Minimum Y (REAL) (default = DUMMY to determine from the data. If input, nearest lt. or eq. external multiple of cell size chosen) MAX_Y: Maximum Y (REAL) (default = DUMMY to determine from the data. If input, nearest gt. or eq. multiple of cell size chosen) MIN_Z: Minimum Z (REAL) (default = DUMMY to determine from the data. If input, nearest lt. or eq. multiple of cell size chosen) MAX_Z: Maximum Z (REAL) (default = DUMMY to determine from the data. If input, nearest gt. or eq. multiple of cell size chosen)A more compact and extensible form of GXVOX.log_grid_points_z_ex. Only the most basic parameters are entered directly. Optional parameters are passed via a GXREG object.

classmethod list_properties_gocad(header, lst)[source]

List all the properties available in this GOCAD file.

Parameters
  • header (str) – Name of GOCAD Voxel file

  • lst (GXLST) – List object to populate

New in version 9.4.

License: Geosoft Open License

classmethod log_grid_points_z_ex_from_gdb(name, error, cell_size, cell_size_z, var_only, min_radius, max_radius, min_points, max_points, model, power, slope, range, nugget, sill, strike, dip, plunge, along_strike_weight, down_dip_weight, log_opt, min_log, type, db, x_channel, y_channel, z_channel, data_channel, ipj)[source]

Log grid a grid3d from a database (using variable Z’s)

Parameters
  • name (str) – Output grid3d filename

  • error (str) – Output error grid3d filename

  • cell_size (float) – Cell size (DUMMY for default)

  • cell_size_z (str) – Cell size in Z (“” for default)

  • var_only (int) – Variogram Only

  • min_radius (float) – Minimum Search Radius (DUMMY for none)

  • max_radius (float) – Maximum Search Radius (DUMMY for none)

  • min_points (int) – Minimum Search Points

  • max_points (int) – Maximum Search Points

  • model (int) – Model number 1-power, 2-sperical, 3-gaussian, 4-exponential

  • power (float) – Power

  • slope (float_ref) – Slope

  • range (float_ref) – Range

  • nugget (float) – Nugget

  • sill (float_ref) – Sill

  • strike (float) – Strike

  • dip (float) – Dip

  • plunge (float) – Plunge

  • along_strike_weight (float) – Strike Weight

  • down_dip_weight (float) – Dip Plane Weight

  • log_opt (int) – VOX_GRID_LOGOPT constants Log Option

  • min_log (float) – Minimum log

  • type (int) – GS_TYPES constants

  • db (GXDB) – Database

  • x_channel (int) – X channel [DB_LOCK_READONLY]

  • y_channel (int) – Y channel [DB_LOCK_READONLY]

  • z_channel (int) – Z channel [DB_LOCK_READONLY]

  • data_channel (int) – Data channel [DB_LOCK_READONLY]

New in version 9.5.

License: Geosoft Open License

classmethod null()[source]

A null (undefined) instance of GXMULTIGRID3DUTIL

Returns

A null GXMULTIGRID3DUTIL

Return type

GXMULTIGRID3DUTIL

RBFKERNEL constants

Math kernel to use in the RBF Computation

RBFKERNEL_DISTANCE

Distance

gxapi.RBFKERNEL_DISTANCE = 0
RBFKERNEL_MULTIQUADRATIC

Multiquadratic

gxapi.RBFKERNEL_MULTIQUADRATIC = 1