GXGU class

class geosoft.gxapi.GXGU
Not a class. A catch-all group of functions performing
various geophysical processes, including the calculation
of simple EM model responses, certain instrument dump
file imports, and 2D Euler deconvolution.
static dipole_mag((str)arg1, (float)arg2, (float)arg3, (int)arg4, (int)arg5, (float)arg6, (float)arg7) → None:
Calculate a dipole magnetic field into XYZ file
Parameters:
  • arg1 (str) – sXYZ
  • arg2 (float) – rDepth
  • arg3 (float) – rInc
  • arg4 (int) – iNX
  • arg5 (int) – iNY
  • arg6 (float) – rDX
  • arg7 (float) – rDY
Returns:

Nothing

Return type:

None

New in version 5.1.6.

static em_half_space_inv((float)arg1, (float)arg2, (int)arg3, (float)arg4, (float)arg5, (GXVV)arg6, (GXVV)arg7, (GXVV)arg8, (GXVV)arg9, (int)arg10, (int)arg11, (float)arg12) → None:
Inverts EM responses to the best halfspace model.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

static em_half_space_vv((float)arg1, (float)arg2, (int)arg3, (GXVV)arg4, (GXVV)arg5, (GXVV)arg6, (GXVV)arg7) → None:
EM Halfspace forward model response.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

static em_layer((float)arg1, (float)arg2, (float)arg3, (int)arg4, (int)arg5, (GXVV)arg6, (GXVV)arg7, (float_ref)arg8, (float_ref)arg9) → int:
Calculate the EM response of a layered earth model.
Parameters:
Returns:

0 of OK 1 if some error

Return type:

int

New in version 5.0.0.

static em_plate((float)arg1, (float)arg2, (float)arg3, (float)arg4, (float)arg5, (float)arg6, (float)arg7, (float)arg8, (float)arg9, (int)arg10, (GXVV)arg11, (int)arg12, (float)arg13, (float)arg14, (float)arg15, (GXVV)arg16, (GXVV)arg17, (GXVV)arg18, (GXVV)arg19, (GXVV)arg20, (GXVV)arg21) → int:
Calculate the conductance of a thin plate model.
Parameters:
  • arg1 (float) – plate strike length (m)
  • arg2 (float) – Plate dip length (m)
  • arg3 (float) – Plate strike (degrees) from X axis
  • arg4 (float) – Plate dip (degrees) from horizontal
  • arg5 (float) – plate plunge (degrees) from horizontal
  • arg6 (float) – Rx offset in X from Tx
  • arg7 (float) – Rx offset in Y from Tx
  • arg8 (float) – Rx offset in Z from Tx (+’ve down)
  • arg9 (float) – Depth below Tx
  • arg10 (int) – EMPLATE_DOMAIN constants
  • arg11 (geosoft.gxapi.GXVV) – The plate conductances (VV length <= 100)
  • arg12 (int) – EMPLATE_TX constants
  • arg13 (float) – Tx frequency (for EMPLATE_TIME)
  • arg14 (float) – Tx time window spacing (for EMPLATE_TIME)
  • arg15 (float) – The frequency/time parameters (SI units: f[Hz] or t[s])
  • arg16 (geosoft.gxapi.GXVV) – On return - X in-phase part (ppm)
  • arg17 (geosoft.gxapi.GXVV) – On return - Y in-phase part (ppm)
  • arg18 (geosoft.gxapi.GXVV) – On return - Z in-phase part (ppm)
  • arg19 (geosoft.gxapi.GXVV) – On return - X quadrature part (ppm)
  • arg20 (geosoft.gxapi.GXVV) – On return - Y quadrature part (ppm)
  • arg21 (geosoft.gxapi.GXVV) – On return - Z quadrature part (ppm)
Returns:

0 of OK 1 if some error

Return type:

int

New in version 5.0.0.

static gen_ux_detect_symbols_group_name((str)arg1, (str)arg2, (str_ref)arg3) → None:
Generate a group name string for UX-Detect symbols
Parameters:
  • arg1 (str) – input Targets database name
  • arg2 (str) – input Targets group (line) name
  • arg3 (geosoft.gxapi.str_ref) – output group name string
Returns:

Nothing

Return type:

None

New in version 6.3.0.

Note:

Start a new group for the symbols in the UX-Detect system.
The Target GDB is often in the form "GDB_Targets", where
"GDB" is the original data. Cut off the part including the
underscore when creating the map, so you don't get map group
Names like "SYMBOLS_UxData_Targets_Targets".
static geometrics2_db((GXDB)arg1, (GXRA)arg2, (GXWA)arg3, (int)arg4, (int)arg5, (int)arg6, (int)arg7, (float)arg8, (float)arg9, (float)arg10, (float)arg11) → None:
Convert a Geometrics STN file to a database.
Parameters:
  • arg1 (geosoft.gxapi.GXDB) – DB handle
  • arg2 (geosoft.gxapi.GXRA) – RA handle, STN file
  • arg3 (geosoft.gxapi.GXWA) – Log file WA handle
  • arg4 (int) – Simple mode (1) or Mapped mode (2)
  • arg5 (int) – Survey line orientation: North-south - 0 East-west - 1
  • arg6 (int) – Starting survey position: SW - 0, NW - 1, SE - 2, NE - 3,
  • arg7 (int) – Bidirectional (0) or Unidirectional (1)
  • arg8 (float) – Starting position X
  • arg9 (float) – Starting position Y
  • arg10 (float) – Mark spacing
  • arg11 (float) – Line spacing
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

Assumes that the database is new and empty. If not, existing channels
with names X, Y, Mag1, Mag2, Time, Date,
and Mark will deleted and then created.  Existing lines will
be erased and then created if they are the same as the new ones.
static geometrics2_tbl((GXRA)arg1, (GXWA)arg2, (GXWA)arg3) → None:
Convert a Geometrics station file (STN) to a table file (TBL)
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

static geometrics_qc((GXWA)arg1, (str)arg2, (GXVV)arg3, (float)arg4, (float)arg5, (float)arg6, (GXVV)arg7, (GXVV)arg8) → None:
Correct reading positions in a database.
Parameters:
  • arg1 (geosoft.gxapi.GXWA) – Output error log file
  • arg2 (str) – Database line number. For output to log file only
  • arg3 (geosoft.gxapi.GXVV) – Input VV, GS_DOUBLE
  • arg4 (float) – Tolerance defined as percentage, say 50.0 means 50%. Must be >=0.0 Lower bound = (Normal Density) - (Normal Density)*Tolerance Upper bound = (Normal Density) + (Normal Density)*Tolerance
  • arg5 (float) – Minimum coordinate (X or Y)
  • arg6 (float) – Maximum coordinate (X or Y)
  • arg7 (geosoft.gxapi.GXVV) – Output VV, GS_DOUBLE
  • arg8 (geosoft.gxapi.GXVV) – Output Flag VV, GS_LONG
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

There are six cases to consider:

Case        Flag  Solutions      Symptons
-------     ----  -------------  -----------------------------

CASE 1A:    0     No correction  Recorded and actual Line lengths same
                                 Reading densities vary slightly (passed
                                 the tolerance test)

CASE 1B:    -1    No correction  Line lengths same
                                 Reading densities vary and cannot
                                 pass the tolerance test

CASE 2A:    1     Corrected by   Recorded line length too short
                  extension      Possilble high readings in segment(s)
                                 Corrected (by extending) and actual
                                 lengths become the same

CASE 2B:    2     Corrected by   Recorded line length too short
                  interpolation  Possilble high readings in segment(s)
                                 Corrected (by extending) and actual
                                 lengths are not same. Interpolation is
                                 then applied

CASE 3A:    1     Corrected by   Recorded line length too long
                  shifting or    Possible low readings in segment(s)
                  (shrank)       Corrected (by shifting) and actual
                                 lengths are same

CASE 3B:    2     Corrected by   Recorded line length too long
                  interpolation  Possible low readings in segment(s)
                                 Corrected (by shifting) and actual
                                 lengths are not same. Interpolation
                                 is then applied


TERMINOLOGY:

Segments:         A segment refers to the distance and its contents between
                  two adjacent fiducial markers

Normal Density:   The density (number of readings) shared by the segments in
                  in a survey line.
                  The number of segments with the density is greater than the
                  number of segments having a different density in a line.

Tolerance and Bound:
                  Tolerance is defined as a percentage, say 50% (=0.5).
                  Based on the tolerance, a lower bound and upper bound

                  can be defined:

                  Lower bound = (Normal Density) - (Normal Density)*Tolerance
                  Upper bound = (Normal Density) - (Normal Density)*Tolerance

                  Segments will pass the tolerance test if the number of readings
                  falls within the Lower and Upper Bounds.
static geonics3138_dump2_db((GXDB)arg1, (GXRA)arg2, (GXRA)arg3, (GXWA)arg4, (float)arg5, (float)arg6) → None:
Convert a Geonics EM31/EM38 file in dump format to a database.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

Assumes that the database is new and empty. If not, existing channels
with names X, Y, Station, Conductivity, Inphase, Quadrature,
and Time will deleted and then created.  Existing lines will
be erased and then created if they are the same as the new ones.
static geonics61_dump2_db((GXDB)arg1, (GXRA)arg2, (GXWA)arg3, (float)arg4, (float)arg5) → None:
Convert a Geonics EM61 file in dump format to a database.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

Assumes that the database is new and empty. If not, existing channels
with names X, Y, Station, Conductivity, Inphase, Quadrature,
and Time will deleted and then created.  Existing lines will
be erased and then created if they are the same as the new ones.
static geonics_dat2_db((GXDB)arg1, (GXRA)arg2, (GXWA)arg3, (float)arg4, (float)arg5) → None:
Convert a Geonics EM31/EM38/EM61 file in DAT format to a database.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

Assumes that the database is new and empty. If not, existing channels
with names X, Y, Station, Conductivity, Inphase, Quadrature,
and Time will deleted and then created.  Existing lines will
be erased and then created if they are the same as the new ones.
static gr_curv_cor((GXVV)arg1, (GXVV)arg2, (GXVV)arg3) → None:
Gravity Curvature (Bullard B) Correction to Bouguer anomaly
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

static gr_curv_cor_ex((GXVV)arg1, (GXVV)arg2, (GXVV)arg3, (float)arg4) → None:
Gravity Curvature (Bullard B) Correction to Bouguer anomaly, with user input cap density.
Parameters:
Returns:

Nothing

Return type:

None

New in version 8.0.1.

static gr_demvv((GXIMG)arg1, (GXVV)arg2, (GXVV)arg3, (GXVV)arg4) → None:
Get gravity DEM grid VV for Bouguer anomaly
Parameters:
Returns:

Nothing

Return type:

None

New in version 6.2.0.

static gr_test((float)arg1, (float)arg2, (float)arg3, (GXVV)arg4, (GXVV)arg5, (GXVV)arg6, (GXVV)arg7, (GXVV)arg8, (GXVV)arg9) → None:
Test triangular prism gravity calculation
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.1.4.

static gravity_still_reading_correction((GXDB)arg1, (int)arg2, (int)arg3, (int)arg4, (str)arg5, (int)arg6) → None:
Gravity Still Reading Correction on selected lines.
Parameters:
  • arg1 (geosoft.gxapi.GXDB) – Database
  • arg2 (int) – Input gravity channel handle [DB_LOCK_READONLY]
  • arg3 (int) – Input date channel handle [DB_LOCK_READONLY]
  • arg4 (int) – Input time channel handle [DB_LOCK_READONLY]
  • arg5 (str) – Still readings file
  • arg6 (int) – Output gravity channel handle [DB_LOCK_READWRITE]
Returns:

Nothing

Return type:

None

New in version 8.5.0.

static import_daarc500_ethernet((str)arg1, (str)arg2, (int_ref)arg3) → None:
Import Ethernet data from the RMS Instruments DAARC500.
Parameters:
  • arg1 (str) – File to import
  • arg2 (str) – Output binary file
  • arg3 (geosoft.gxapi.int_ref) – Returned number of bytes per block
Returns:

Nothing

Return type:

None

New in version 7.2.0.

Note:

Imports Ethernet data recorded
by the RMS Instruments DAARC500 instrument, and outputs the data
to a new binary file, returning the number of bytes per
block, to make it easier to import the data using the regular binary import.
static import_daarc500_serial((str)arg1, (int)arg2, (str)arg3, (int_ref)arg4) → None:
Import Serial data from the RMS Instruments DAARC500.
Parameters:
  • arg1 (str) – File to import
  • arg2 (int) – Channel to import, 1-8
  • arg3 (str) – Output binary file
  • arg4 (geosoft.gxapi.int_ref) – Returned number of bytes per block
Returns:

Nothing

Return type:

None

New in version 7.2.0.

Note:

Imports a single channel of the up to 8 serial data channels recorded
by the RMS Instruments DAARC500 instrument, and outputs the data for
that channel to a new binary file, returning the number of bytes per
block, to make it easier to import the data using the regular binary import.
static import_p190((GXDB)arg1, (str)arg2, (str)arg3, (GXWA)arg4) → None:
Import navigation data in the P190 format.
Parameters:
  • arg1 (geosoft.gxapi.GXDB) – Database handle
  • arg2 (str) – P190 file name
  • arg3 (str) – Single letter code, e.g. “C”, “E”, “S”, “T” or “V”, or blank for all records.
  • arg4 (geosoft.gxapi.GXWA) – Log file
Returns:

Nothing

Return type:

None

New in version 6.3.0.

Note:

Imports the data, and, if projection information is included
set the "X" and "Y" channel projection info. (Note: the last file
imported always takes precedence).
Different record types are imported to separate lines, but in the
same order as in the file. Data in existing lines is overwritten.
If the record type is specified, only records beginning with that
letter are imported, otherwise all records (except for the header "H"
records) are imported.
static lag_daarc500_gps((GXVV)arg1, (GXVV)arg2, (GXVV)arg3) → None:
Lag the GPS fid values for the DAARC500 import.
Parameters:
Returns:

Nothing

Return type:

None

New in version 7.2.0.

Note:

The fiducial times recorded for the GPS in the RMS Instrument DAARC500
are delayed, and associated with the "wrong" fid value. They should actually
be moved to the previous fid value in the mag data where the event flag is non-zero.
static maxwell_plate_corners((float)arg1, (float)arg2, (float)arg3, (float)arg4, (float)arg5, (float)arg6, (float)arg7, (float)arg8, (float_ref)arg9, (float_ref)arg10, (float_ref)arg11, (float_ref)arg12, (float_ref)arg13, (float_ref)arg14, (float_ref)arg15, (float_ref)arg16, (float_ref)arg17, (float_ref)arg18, (float_ref)arg19, (float_ref)arg20) → None:
Calculate the corner point locations for a Maxwell Plate.
Parameters:
Returns:

Nothing

Return type:

None

New in version 6.1.0.

Note:

This routine calculates the corner locations of plates defined in the Maxwell Plate
program, given the top-center location and plate geometry parameters.
static scan_daarc500_ethernet((str)arg1, (int_ref)arg2, (int_ref)arg3) → None:
Scan Ethernet data from the RMS Instruments DAARC500.
Parameters:
Returns:

Nothing

Return type:

None

New in version 7.2.0.

Note:

Scans the file to see what data type is in the Ethernet file.
Currently only detects GR820 types.
static scan_daarc500_serial((str)arg1, (GXVV)arg2, (GXVV)arg3) → None:
Scan Serial data from the RMS Instruments DAARC500.
Parameters:
Returns:

Nothing

Return type:

None

New in version 7.2.0.

Note:

Scans the file to see which of the 8 serial channels were used to store data.
static vv_euler((GXVV)arg1, (GXVV)arg2, (GXIMG)arg3, (GXIMG)arg4, (GXIMG)arg5, (GXIMG)arg6, (GXVV)arg7, (GXVV)arg8, (GXVV)arg9, (GXVV)arg10, (GXVV)arg11, (GXVV)arg12, (int)arg13, (float)arg14, (float)arg15, (int)arg16) → None:
Get Euler solutions of depth from VVs and grids.
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

All VVs must be REAL

The output X and Y values are the same as the inputs,
except if PEAKEULER_XY_FIT is selected. All other
output values are set to dummy if:
     a) The input X or Y is a dummy
     b) The derived window size is a dummy.
     c) The derived solution is outside the range
     d) The solution is invalid (singular matrix)
static vv_euler2((GXVV)arg1, (GXVV)arg2, (GXIMG)arg3, (GXIMG)arg4, (GXIMG)arg5, (GXIMG)arg6, (GXVV)arg7, (GXVV)arg8, (GXVV)arg9, (GXVV)arg10, (GXVV)arg11, (GXVV)arg12, (GXVV)arg13, (float)arg14, (float)arg15, (int)arg16) → None:
Get Euler solutions of depth from VVs and grids (method 2).
Parameters:
Returns:

Nothing

Return type:

None

New in version 5.0.0.

Note:

All VVs must be REAL

EM_ERR constants

Error Scaling
gxapi.EM_ERR_UNSCALED = 0
gxapi.EM_ERR_LOGSCALING = 1

EM_INV constants

Type of Inversion
gxapi.EM_INV_INPHASE = 0
gxapi.EM_INV_QUADRATURE = 1
gxapi.EM_INV_BOTH = 2

EMPLATE_DOMAIN constants

Type of Domain
gxapi.EMPLATE_FREQUENCY = 1
gxapi.EMPLATE_TIME = 9

EMPLATE_TX constants

Orientation
gxapi.EMPLATE_TX_X = 1
gxapi.EMPLATE_TX_Y = 2
gxapi.EMPLATE_TX_Z = 3

GU_DAARC500_DATATYPE constants

Supported serial data types for import
gxapi.GU_DAARC500_UNKNOWN = 0
gxapi.GU_DAARC500_GENERIC_ASCII = 1
gxapi.GU_DAARC500_GPS = 2
gxapi.GU_DAARC500_GR820_256D = 3
gxapi.GU_DAARC500_GR820_256DU = 4
gxapi.GU_DAARC500_GR820_512DU = 5
gxapi.GU_DAARC500_NAV = 6

PEAKEULER_XY constants

Fit Options
gxapi.PEAKEULER_XY_NOFIT = 0
gxapi.PEAKEULER_XY_FIT = 1