License Required for gxgrd.Grid.minimum_curvature ?
EdwardBiegert
Posts: 4
(1) Is there a license restriction for running gxgrd.Grid.minimum_curvature from stand-alone python script?
(2) If so, where in the documentation can I find license restrictions for various functions?
(3) Or is there another problem?
I am running the OM Viewer and this script (pretty much straight from the documentation) failed:
import numpy as np
import geosoft.gxpy as gxpy
import geosoft.gxpy.grid as gxgrd
# ******************************************************
# Gridding test
gxc = gxpy.gx.GXpy() # create Geosoft context
print(gxc.gid) # Prints Geosoft userID
xyv = [(45., 10., 100), (60., 25., 77.), (50., 8., 80.)] # simple data array
grid = gxgrd.Grid.minimum_curvature(xyv)
print('Properties ', grid.properties())
exit()
This is the python response:
C:\ProgramData\Anaconda3\python.exe C:/Users/EKB/PycharmProjects/Test_Project/GX_GDB_Gridding_Failure.py
biegert@alumni.rice.edu
Traceback (most recent call last):
File "C:/Users/EKB/PycharmProjects/Test_Project/GX_GDB_Gridding_Failure.py", line 11, in
grid = gxgrd.Grid.minimum_curvature(xyv)
File "c:\programdata\anaconda3\lib\site-packages\geosoft\gxpy\grid.py", line 705, in minimum_curvature
gxapi.GXRGRD.run2(gdb.gxdb, xc, yc, vc, con_file, file_name)
File "c:\programdata\anaconda3\lib\site-packages\geosoft\gxapi\GXRGRD.py", line 226, in run2
ret_val = gxapi_cy.WrapRGRD._run2(GXContext._get_tls_geo(), db, x.encode(), y.encode(), z.encode(), ctl.encode(), grd.encode())
File "gxapi_cy.pyx", line 54084, in gxapi_cy.WrapRGRD._run2
File "gxapi_cy.pyx", line 11118, in gxapi_cy._raise_on_gx_errors
geosoft.gxapi.GXAPIError: Unable to bind the "?iRun2_RGRD@@YAJPEAVH_GXX@@PEBJPEBD2222@Z" wrapper function. This might be due to a missing DLL or license, or you are running an application outside of Oasis montaj.
Process finished with exit code 1
(2) If so, where in the documentation can I find license restrictions for various functions?
(3) Or is there another problem?
I am running the OM Viewer and this script (pretty much straight from the documentation) failed:
import numpy as np
import geosoft.gxpy as gxpy
import geosoft.gxpy.grid as gxgrd
# ******************************************************
# Gridding test
gxc = gxpy.gx.GXpy() # create Geosoft context
print(gxc.gid) # Prints Geosoft userID
xyv = [(45., 10., 100), (60., 25., 77.), (50., 8., 80.)] # simple data array
grid = gxgrd.Grid.minimum_curvature(xyv)
print('Properties ', grid.properties())
exit()
This is the python response:
C:\ProgramData\Anaconda3\python.exe C:/Users/EKB/PycharmProjects/Test_Project/GX_GDB_Gridding_Failure.py
biegert@alumni.rice.edu
Traceback (most recent call last):
File "C:/Users/EKB/PycharmProjects/Test_Project/GX_GDB_Gridding_Failure.py", line 11, in
grid = gxgrd.Grid.minimum_curvature(xyv)
File "c:\programdata\anaconda3\lib\site-packages\geosoft\gxpy\grid.py", line 705, in minimum_curvature
gxapi.GXRGRD.run2(gdb.gxdb, xc, yc, vc, con_file, file_name)
File "c:\programdata\anaconda3\lib\site-packages\geosoft\gxapi\GXRGRD.py", line 226, in run2
ret_val = gxapi_cy.WrapRGRD._run2(GXContext._get_tls_geo(), db, x.encode(), y.encode(), z.encode(), ctl.encode(), grd.encode())
File "gxapi_cy.pyx", line 54084, in gxapi_cy.WrapRGRD._run2
File "gxapi_cy.pyx", line 11118, in gxapi_cy._raise_on_gx_errors
geosoft.gxapi.GXAPIError: Unable to bind the "?iRun2_RGRD@@YAJPEAVH_GXX@@PEBJPEBD2222@Z" wrapper function. This might be due to a missing DLL or license, or you are running an application outside of Oasis montaj.
Process finished with exit code 1
Tagged:
0
Comments
-
Same question.0
-
My guess is that the answer is 1. This page explains that this error will be thrown in the case of trying to use unlicensed functions (https://geosoftgxdev.atlassian.net/wiki/spaces/GD/pages/14582245/Understanding+License+Controls ) It is difficult to unwrap but the GXAPI CLASS for rangrid GXGRD is listed as being for Extended Licenses only (https://geosoftinc.github.io/gxpy/9.10/python/GXRGRD.html ). The definition of this is a bit vague but it requires at least an Oasis license. It appears to have been the case since v9.3 (according to the documentation).0