idx
int64
0
252k
question
stringlengths
48
5.28k
target
stringlengths
5
1.23k
247,500
def dafec ( handle , bufsiz , lenout = _default_len_out ) : handle = ctypes . c_int ( handle ) buffer = stypes . emptyCharArray ( yLen = bufsiz , xLen = lenout ) bufsiz = ctypes . c_int ( bufsiz ) lenout = ctypes . c_int ( lenout ) n = ctypes . c_int ( ) done = ctypes . c_int ( ) libspice . dafec_c ( handle , bufsiz , ...
Extract comments from the comment area of a binary DAF .
247,501
def dafopr ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . dafopr_c ( fname , ctypes . byref ( handle ) ) return handle . value
Open a DAF for subsequent read requests .
247,502
def dafopw ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . dafopw_c ( fname , ctypes . byref ( handle ) ) return handle . value
Open a DAF for subsequent write requests .
247,503
def dafrfr ( handle , lenout = _default_len_out ) : handle = ctypes . c_int ( handle ) lenout = ctypes . c_int ( lenout ) nd = ctypes . c_int ( ) ni = ctypes . c_int ( ) ifname = stypes . stringToCharP ( lenout ) fward = ctypes . c_int ( ) bward = ctypes . c_int ( ) free = ctypes . c_int ( ) libspice . dafrfr_c ( handl...
Read the contents of the file record of a DAF .
247,504
def dafrs ( insum ) : insum = stypes . toDoubleVector ( insum ) libspice . dafrs_c ( ctypes . byref ( insum ) )
Change the summary for the current array in the current DAF .
247,505
def dafus ( insum , nd , ni ) : insum = stypes . toDoubleVector ( insum ) dc = stypes . emptyDoubleVector ( nd ) ic = stypes . emptyIntVector ( ni ) nd = ctypes . c_int ( nd ) ni = ctypes . c_int ( ni ) libspice . dafus_c ( insum , nd , ni , dc , ic ) return stypes . cVectorToPython ( dc ) , stypes . cVectorToPython ( ...
Unpack an array summary into its double precision and integer components .
247,506
def dasac ( handle , buffer ) : handle = ctypes . c_int ( handle ) n = ctypes . c_int ( len ( buffer ) ) buflen = ctypes . c_int ( max ( len ( s ) for s in buffer ) + 1 ) buffer = stypes . listToCharArrayPtr ( buffer ) libspice . dasac_c ( handle , n , buflen , buffer )
Add comments from a buffer of character strings to the comment area of a binary DAS file appending them to any comments which are already present in the file s comment area .
247,507
def dasec ( handle , bufsiz = _default_len_out , buflen = _default_len_out ) : handle = ctypes . c_int ( handle ) buffer = stypes . emptyCharArray ( buflen , bufsiz ) bufsiz = ctypes . c_int ( bufsiz ) buflen = ctypes . c_int ( buflen ) n = ctypes . c_int ( 0 ) done = ctypes . c_int ( ) libspice . dasec_c ( handle , bu...
Extract comments from the comment area of a binary DAS file .
247,508
def dasopr ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . dasopr_c ( fname , ctypes . byref ( handle ) ) return handle . value
Open a DAS file for reading .
247,509
def dcyldr ( x , y , z ) : x = ctypes . c_double ( x ) y = ctypes . c_double ( y ) z = ctypes . c_double ( z ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . dcyldr_c ( x , y , z , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from rectangular to cylindrical coordinates .
247,510
def dgeodr ( x , y , z , re , f ) : x = ctypes . c_double ( x ) y = ctypes . c_double ( y ) z = ctypes . c_double ( z ) re = ctypes . c_double ( re ) f = ctypes . c_double ( f ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . dgeodr_c ( x , y , z , re , f , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from rectangular to geodetic coordinates .
247,511
def diags2 ( symmat ) : symmat = stypes . toDoubleMatrix ( symmat ) diag = stypes . emptyDoubleMatrix ( x = 2 , y = 2 ) rotateout = stypes . emptyDoubleMatrix ( x = 2 , y = 2 ) libspice . diags2_c ( symmat , diag , rotateout ) return stypes . cMatrixToNumpy ( diag ) , stypes . cMatrixToNumpy ( rotateout )
Diagonalize a symmetric 2x2 matrix .
247,512
def dlatdr ( x , y , z ) : x = ctypes . c_double ( x ) y = ctypes . c_double ( y ) z = ctypes . c_double ( z ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . dlatdr_c ( x , y , z , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from rectangular to latitudinal coordinates .
247,513
def dp2hx ( number , lenout = _default_len_out ) : number = ctypes . c_double ( number ) lenout = ctypes . c_int ( lenout ) string = stypes . stringToCharP ( lenout ) length = ctypes . c_int ( ) libspice . dp2hx_c ( number , lenout , string , ctypes . byref ( length ) ) return stypes . toPythonString ( string )
Convert a double precision number to an equivalent character string using base 16 scientific notation .
247,514
def dpgrdr ( body , x , y , z , re , f ) : body = stypes . stringToCharP ( body ) x = ctypes . c_double ( x ) y = ctypes . c_double ( y ) z = ctypes . c_double ( z ) re = ctypes . c_double ( re ) f = ctypes . c_double ( f ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . dpgrdr_c ( body , x , y , z , re , f , jacobi...
This routine computes the Jacobian matrix of the transformation from rectangular to planetographic coordinates .
247,515
def drdcyl ( r , lon , z ) : r = ctypes . c_double ( r ) lon = ctypes . c_double ( lon ) z = ctypes . c_double ( z ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . drdcyl_c ( r , lon , z , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from cylindrical to rectangular coordinates .
247,516
def drdgeo ( lon , lat , alt , re , f ) : lon = ctypes . c_double ( lon ) lat = ctypes . c_double ( lat ) alt = ctypes . c_double ( alt ) re = ctypes . c_double ( re ) f = ctypes . c_double ( f ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . drdgeo_c ( lon , lat , alt , re , f , jacobi ) return stypes . cMatrixToN...
This routine computes the Jacobian of the transformation from geodetic to rectangular coordinates .
247,517
def drdlat ( r , lon , lat ) : r = ctypes . c_double ( r ) lon = ctypes . c_double ( lon ) lat = ctypes . c_double ( lat ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . drdlat_c ( r , lon , lat , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
Compute the Jacobian of the transformation from latitudinal to rectangular coordinates .
247,518
def drdpgr ( body , lon , lat , alt , re , f ) : body = stypes . stringToCharP ( body ) lon = ctypes . c_double ( lon ) lat = ctypes . c_double ( lat ) alt = ctypes . c_double ( alt ) re = ctypes . c_double ( re ) f = ctypes . c_double ( f ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . drdpgr_c ( body , lon , lat...
This routine computes the Jacobian matrix of the transformation from planetographic to rectangular coordinates .
247,519
def drdsph ( r , colat , lon ) : r = ctypes . c_double ( r ) colat = ctypes . c_double ( colat ) lon = ctypes . c_double ( lon ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . drdsph_c ( r , colat , lon , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from spherical to rectangular coordinates .
247,520
def dskb02 ( handle , dladsc ) : handle = ctypes . c_int ( handle ) nv = ctypes . c_int ( 0 ) np = ctypes . c_int ( 0 ) nvxtot = ctypes . c_int ( 0 ) vtxbds = stypes . emptyDoubleMatrix ( 3 , 2 ) voxsiz = ctypes . c_double ( 0.0 ) voxori = stypes . emptyDoubleVector ( 3 ) vgrext = stypes . emptyIntVector ( 3 ) cgscal =...
Return bookkeeping data from a DSK type 2 segment .
247,521
def dskcls ( handle , optmiz = False ) : handle = ctypes . c_int ( handle ) optmiz = ctypes . c_int ( optmiz ) libspice . dskcls_c ( handle , optmiz )
Close a DSK file .
247,522
def dskd02 ( handle , dladsc , item , start , room ) : handle = ctypes . c_int ( handle ) item = ctypes . c_int ( item ) start = ctypes . c_int ( start ) room = ctypes . c_int ( room ) n = ctypes . c_int ( 0 ) values = stypes . emptyDoubleVector ( room ) libspice . dskd02_c ( handle , dladsc , item , start , room , cty...
Fetch double precision data from a type 2 DSK segment .
247,523
def dskgd ( handle , dladsc ) : handle = ctypes . c_int ( handle ) dskdsc = stypes . SpiceDSKDescr ( ) libspice . dskgd_c ( handle , ctypes . byref ( dladsc ) , ctypes . byref ( dskdsc ) ) return dskdsc
Return the DSK descriptor from a DSK segment identified by a DAS handle and DLA descriptor .
247,524
def dski02 ( handle , dladsc , item , start , room ) : handle = ctypes . c_int ( handle ) item = ctypes . c_int ( item ) start = ctypes . c_int ( start ) room = ctypes . c_int ( room ) n = ctypes . c_int ( ) values = stypes . emptyIntVector ( room ) libspice . dski02_c ( handle , dladsc , item , start , room , ctypes ....
Fetch integer data from a type 2 DSK segment .
247,525
def dskmi2 ( vrtces , plates , finscl , corscl , worksz , voxpsz , voxlsz , makvtl , spxisz ) : nv = ctypes . c_int ( len ( vrtces ) ) vrtces = stypes . toDoubleMatrix ( vrtces ) np = ctypes . c_int ( len ( plates ) ) plates = stypes . toIntMatrix ( plates ) finscl = ctypes . c_double ( finscl ) corscl = ctypes . c_int...
Make spatial index for a DSK type 2 segment . The index is returned as a pair of arrays one of type int and one of type float . These arrays are suitable for use with the DSK type 2 writer dskw02 .
247,526
def dskn02 ( handle , dladsc , plid ) : handle = ctypes . c_int ( handle ) plid = ctypes . c_int ( plid ) normal = stypes . emptyDoubleVector ( 3 ) libspice . dskn02_c ( handle , dladsc , plid , normal ) return stypes . cVectorToPython ( normal )
Compute the unit normal vector for a specified plate from a type 2 DSK segment .
247,527
def dskp02 ( handle , dladsc , start , room ) : handle = ctypes . c_int ( handle ) start = ctypes . c_int ( start ) room = ctypes . c_int ( room ) n = ctypes . c_int ( 0 ) plates = stypes . emptyIntMatrix ( 3 , room ) libspice . dskp02_c ( handle , dladsc , start , room , ctypes . byref ( n ) , plates ) return stypes ....
Fetch triangular plates from a type 2 DSK segment .
247,528
def dskrb2 ( vrtces , plates , corsys , corpar ) : nv = ctypes . c_int ( len ( vrtces ) ) vrtces = stypes . toDoubleMatrix ( vrtces ) np = ctypes . c_int ( len ( plates ) ) plates = stypes . toIntMatrix ( plates ) corsys = ctypes . c_int ( corsys ) corpar = stypes . toDoubleVector ( corpar ) mncor3 = ctypes . c_double ...
Determine range bounds for a set of triangular plates to be stored in a type 2 DSK segment .
247,529
def dskv02 ( handle , dladsc , start , room ) : handle = ctypes . c_int ( handle ) start = ctypes . c_int ( start ) room = ctypes . c_int ( room ) n = ctypes . c_int ( ) vrtces = stypes . emptyDoubleMatrix ( 3 , room ) libspice . dskv02_c ( handle , dladsc , start , room , ctypes . byref ( n ) , vrtces ) return stypes ...
Fetch vertices from a type 2 DSK segment .
247,530
def dskw02 ( handle , center , surfid , dclass , fname , corsys , corpar , mncor1 , mxcor1 , mncor2 , mxcor2 , mncor3 , mxcor3 , first , last , vrtces , plates , spaixd , spaixi ) : handle = ctypes . c_int ( handle ) center = ctypes . c_int ( center ) surfid = ctypes . c_int ( surfid ) dclass = ctypes . c_int ( dclass ...
Write a type 2 segment to a DSK file .
247,531
def dskx02 ( handle , dladsc , vertex , raydir ) : handle = ctypes . c_int ( handle ) vertex = stypes . toDoubleVector ( vertex ) raydir = stypes . toDoubleVector ( raydir ) plid = ctypes . c_int ( ) xpt = stypes . emptyDoubleVector ( 3 ) found = ctypes . c_int ( ) libspice . dskx02_c ( handle , ctypes . byref ( dladsc...
Determine the plate ID and body - fixed coordinates of the intersection of a specified ray with the surface defined by a type 2 DSK plate model .
247,532
def dskxv ( pri , target , srflst , et , fixref , vtxarr , dirarr ) : pri = ctypes . c_int ( pri ) target = stypes . stringToCharP ( target ) nsurf = ctypes . c_int ( len ( srflst ) ) srflst = stypes . toIntVector ( srflst ) et = ctypes . c_double ( et ) fixref = stypes . stringToCharP ( fixref ) nray = ctypes . c_int ...
Compute ray - surface intercepts for a set of rays using data provided by multiple loaded DSK segments .
247,533
def dsphdr ( x , y , z ) : x = ctypes . c_double ( x ) y = ctypes . c_double ( y ) z = ctypes . c_double ( z ) jacobi = stypes . emptyDoubleMatrix ( ) libspice . dsphdr_c ( x , y , z , jacobi ) return stypes . cMatrixToNumpy ( jacobi )
This routine computes the Jacobian of the transformation from rectangular to spherical coordinates .
247,534
def dtpool ( name ) : name = stypes . stringToCharP ( name ) found = ctypes . c_int ( ) n = ctypes . c_int ( ) typeout = ctypes . c_char ( ) libspice . dtpool_c ( name , ctypes . byref ( found ) , ctypes . byref ( n ) , ctypes . byref ( typeout ) ) return n . value , stypes . toPythonString ( typeout . value ) , bool (...
Return the data about a kernel pool variable .
247,535
def ducrss ( s1 , s2 ) : assert len ( s1 ) is 6 and len ( s2 ) is 6 s1 = stypes . toDoubleVector ( s1 ) s2 = stypes . toDoubleVector ( s2 ) sout = stypes . emptyDoubleVector ( 6 ) libspice . ducrss_c ( s1 , s2 , sout ) return stypes . cVectorToPython ( sout )
Compute the unit vector parallel to the cross product of two 3 - dimensional vectors and the derivative of this unit vector .
247,536
def dvcrss ( s1 , s2 ) : assert len ( s1 ) is 6 and len ( s2 ) is 6 s1 = stypes . toDoubleVector ( s1 ) s2 = stypes . toDoubleVector ( s2 ) sout = stypes . emptyDoubleVector ( 6 ) libspice . dvcrss_c ( s1 , s2 , sout ) return stypes . cVectorToPython ( sout )
Compute the cross product of two 3 - dimensional vectors and the derivative of this cross product .
247,537
def dvdot ( s1 , s2 ) : assert len ( s1 ) is 6 and len ( s2 ) is 6 s1 = stypes . toDoubleVector ( s1 ) s2 = stypes . toDoubleVector ( s2 ) return libspice . dvdot_c ( s1 , s2 )
Compute the derivative of the dot product of two double precision position vectors .
247,538
def dvhat ( s1 ) : assert len ( s1 ) is 6 s1 = stypes . toDoubleVector ( s1 ) sout = stypes . emptyDoubleVector ( 6 ) libspice . dvhat_c ( s1 , sout ) return stypes . cVectorToPython ( sout )
Find the unit vector corresponding to a state vector and the derivative of the unit vector .
247,539
def dvnorm ( state ) : assert len ( state ) is 6 state = stypes . toDoubleVector ( state ) return libspice . dvnorm_c ( state )
Function to calculate the derivative of the norm of a 3 - vector .
247,540
def dvsep ( s1 , s2 ) : assert len ( s1 ) is 6 and len ( s2 ) is 6 s1 = stypes . toDoubleVector ( s1 ) s2 = stypes . toDoubleVector ( s2 ) return libspice . dvsep_c ( s1 , s2 )
Calculate the time derivative of the separation angle between two input states S1 and S2 .
247,541
def edlimb ( a , b , c , viewpt ) : limb = stypes . Ellipse ( ) a = ctypes . c_double ( a ) b = ctypes . c_double ( b ) c = ctypes . c_double ( c ) viewpt = stypes . toDoubleVector ( viewpt ) libspice . edlimb_c ( a , b , c , viewpt , ctypes . byref ( limb ) ) return limb
Find the limb of a triaxial ellipsoid viewed from a specified point .
247,542
def edterm ( trmtyp , source , target , et , fixref , abcorr , obsrvr , npts ) : trmtyp = stypes . stringToCharP ( trmtyp ) source = stypes . stringToCharP ( source ) target = stypes . stringToCharP ( target ) et = ctypes . c_double ( et ) fixref = stypes . stringToCharP ( fixref ) abcorr = stypes . stringToCharP ( abc...
Compute a set of points on the umbral or penumbral terminator of a specified target body where the target shape is modeled as an ellipsoid .
247,543
def ekacec ( handle , segno , recno , column , nvals , cvals , isnull ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( nvals ) vallen = ctypes . c_int ( len ( max ( cvals , key = len ) ) + 1 ) cva...
Add data to a character column in a specified EK record .
247,544
def ekacei ( handle , segno , recno , column , nvals , ivals , isnull ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( nvals ) ivals = stypes . toIntVector ( ivals ) isnull = ctypes . c_int ( isnu...
Add data to an integer column in a specified EK record .
247,545
def ekaclc ( handle , segno , column , vallen , cvals , entszs , nlflgs , rcptrs , wkindx ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) column = stypes . stringToCharP ( column ) vallen = ctypes . c_int ( vallen ) cvals = stypes . listToCharArrayPtr ( cvals ) entszs = stypes . toIntVector ( en...
Add an entire character column to an EK segment .
247,546
def ekacld ( handle , segno , column , dvals , entszs , nlflgs , rcptrs , wkindx ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) column = stypes . stringToCharP ( column ) dvals = stypes . toDoubleVector ( dvals ) entszs = stypes . toIntVector ( entszs ) nlflgs = stypes . toIntVector ( nlflgs ) ...
Add an entire double precision column to an EK segment .
247,547
def ekacli ( handle , segno , column , ivals , entszs , nlflgs , rcptrs , wkindx ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) column = stypes . stringToCharP ( column ) ivals = stypes . toIntVector ( ivals ) entszs = stypes . toIntVector ( entszs ) nlflgs = stypes . toIntVector ( nlflgs ) rcp...
Add an entire integer column to an EK segment .
247,548
def ekappr ( handle , segno ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( ) libspice . ekappr_c ( handle , segno , ctypes . byref ( recno ) ) return recno . value
Append a new empty record at the end of a specified E - kernel segment .
247,549
def ekbseg ( handle , tabnam , cnames , decls ) : handle = ctypes . c_int ( handle ) tabnam = stypes . stringToCharP ( tabnam ) ncols = ctypes . c_int ( len ( cnames ) ) cnmlen = ctypes . c_int ( len ( max ( cnames , key = len ) ) + 1 ) cnames = stypes . listToCharArrayPtr ( cnames ) declen = ctypes . c_int ( len ( max...
Start a new segment in an E - kernel .
247,550
def ekccnt ( table ) : table = stypes . stringToCharP ( table ) ccount = ctypes . c_int ( ) libspice . ekccnt_c ( table , ctypes . byref ( ccount ) ) return ccount . value
Return the number of distinct columns in a specified currently loaded table .
247,551
def ekcii ( table , cindex , lenout = _default_len_out ) : table = stypes . stringToCharP ( table ) cindex = ctypes . c_int ( cindex ) lenout = ctypes . c_int ( lenout ) column = stypes . stringToCharP ( lenout ) attdsc = stypes . SpiceEKAttDsc ( ) libspice . ekcii_c ( table , cindex , lenout , column , ctypes . byref ...
Return attribute information about a column belonging to a loaded EK table specifying the column by table and index .
247,552
def ekdelr ( handle , segno , recno ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) libspice . ekdelr_c ( handle , segno , recno )
Delete a specified record from a specified E - kernel segment .
247,553
def ekffld ( handle , segno , rcptrs ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) rcptrs = stypes . toIntVector ( rcptrs ) libspice . ekffld_c ( handle , segno , ctypes . cast ( rcptrs , ctypes . POINTER ( ctypes . c_int ) ) )
Complete a fast write operation on a new E - kernel segment .
247,554
def ekfind ( query , lenout = _default_len_out ) : query = stypes . stringToCharP ( query ) lenout = ctypes . c_int ( lenout ) nmrows = ctypes . c_int ( ) error = ctypes . c_int ( ) errmsg = stypes . stringToCharP ( lenout ) libspice . ekfind_c ( query , lenout , ctypes . byref ( nmrows ) , ctypes . byref ( error ) , e...
Find E - kernel data that satisfy a set of constraints .
247,555
def ekgc ( selidx , row , element , lenout = _default_len_out ) : selidx = ctypes . c_int ( selidx ) row = ctypes . c_int ( row ) element = ctypes . c_int ( element ) lenout = ctypes . c_int ( lenout ) null = ctypes . c_int ( ) found = ctypes . c_int ( ) cdata = stypes . stringToCharP ( lenout ) libspice . ekgc_c ( sel...
Return an element of an entry in a column of character type in a specified row .
247,556
def ekgd ( selidx , row , element ) : selidx = ctypes . c_int ( selidx ) row = ctypes . c_int ( row ) element = ctypes . c_int ( element ) ddata = ctypes . c_double ( ) null = ctypes . c_int ( ) found = ctypes . c_int ( ) libspice . ekgd_c ( selidx , row , element , ctypes . byref ( ddata ) , ctypes . byref ( null ) , ...
Return an element of an entry in a column of double precision type in a specified row .
247,557
def ekgi ( selidx , row , element ) : selidx = ctypes . c_int ( selidx ) row = ctypes . c_int ( row ) element = ctypes . c_int ( element ) idata = ctypes . c_int ( ) null = ctypes . c_int ( ) found = ctypes . c_int ( ) libspice . ekgi_c ( selidx , row , element , ctypes . byref ( idata ) , ctypes . byref ( null ) , cty...
Return an element of an entry in a column of integer type in a specified row .
247,558
def ekifld ( handle , tabnam , ncols , nrows , cnmlen , cnames , declen , decls ) : handle = ctypes . c_int ( handle ) tabnam = stypes . stringToCharP ( tabnam ) ncols = ctypes . c_int ( ncols ) nrows = ctypes . c_int ( nrows ) cnmlen = ctypes . c_int ( cnmlen ) cnames = stypes . listToCharArray ( cnames ) declen = cty...
Initialize a new E - kernel segment to allow fast writing .
247,559
def ekinsr ( handle , segno , recno ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) libspice . ekinsr_c ( handle , segno , recno )
Add a new empty record to a specified E - kernel segment at a specified index .
247,560
def eklef ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . eklef_c ( fname , ctypes . byref ( handle ) ) return handle . value
Load an EK file making it accessible to the EK readers .
247,561
def eknelt ( selidx , row ) : selidx = ctypes . c_int ( selidx ) row = ctypes . c_int ( row ) return libspice . eknelt_c ( selidx , row )
Return the number of elements in a specified column entry in the current row .
247,562
def ekntab ( ) : n = ctypes . c_int ( 0 ) libspice . ekntab_c ( ctypes . byref ( n ) ) return n . value
Return the number of loaded EK tables .
247,563
def ekopn ( fname , ifname , ncomch ) : fname = stypes . stringToCharP ( fname ) ifname = stypes . stringToCharP ( ifname ) ncomch = ctypes . c_int ( ncomch ) handle = ctypes . c_int ( ) libspice . ekopn_c ( fname , ifname , ncomch , ctypes . byref ( handle ) ) return handle . value
Open a new E - kernel file and prepare the file for writing .
247,564
def ekopr ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . ekopr_c ( fname , ctypes . byref ( handle ) ) return handle . value
Open an existing E - kernel file for reading .
247,565
def ekopw ( fname ) : fname = stypes . stringToCharP ( fname ) handle = ctypes . c_int ( ) libspice . ekopw_c ( fname , ctypes . byref ( handle ) ) return handle . value
Open an existing E - kernel file for writing .
247,566
def ekpsel ( query , msglen , tablen , collen ) : query = stypes . stringToCharP ( query ) msglen = ctypes . c_int ( msglen ) tablen = ctypes . c_int ( tablen ) collen = ctypes . c_int ( collen ) n = ctypes . c_int ( ) xbegs = stypes . emptyIntVector ( _SPICE_EK_MAXQSEL ) xends = stypes . emptyIntVector ( _SPICE_EK_MAX...
Parse the SELECT clause of an EK query returning full particulars concerning each selected item .
247,567
def ekrcec ( handle , segno , recno , column , lenout , nelts = _SPICE_EK_EKRCEX_ROOM_DEFAULT ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) lenout = ctypes . c_int ( lenout ) nvals = ctypes . c_int ( ) cvals = stypes ....
Read data from a character column in a specified EK record .
247,568
def ekrced ( handle , segno , recno , column , nelts = _SPICE_EK_EKRCEX_ROOM_DEFAULT ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( 0 ) dvals = stypes . emptyDoubleVector ( nelts ) isnull = ctyp...
Read data from a double precision column in a specified EK record .
247,569
def ekrcei ( handle , segno , recno , column , nelts = _SPICE_EK_EKRCEX_ROOM_DEFAULT ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( ) ivals = stypes . emptyIntVector ( nelts ) isnull = ctypes . ...
Read data from an integer column in a specified EK record .
247,570
def ekssum ( handle , segno ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) segsum = stypes . SpiceEKSegSum ( ) libspice . ekssum_c ( handle , segno , ctypes . byref ( segsum ) ) return segsum
Return summary information for a specified segment in a specified EK .
247,571
def ektnam ( n , lenout = _default_len_out ) : n = ctypes . c_int ( n ) lenout = ctypes . c_int ( lenout ) table = stypes . stringToCharP ( lenout ) libspice . ektnam_c ( n , lenout , table ) return stypes . toPythonString ( table )
Return the name of a specified loaded table .
247,572
def ekucec ( handle , segno , recno , column , nvals , cvals , isnull ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( nvals ) vallen = ctypes . c_int ( len ( max ( cvals , key = len ) ) + 1 ) cva...
Update a character column entry in a specified EK record .
247,573
def ekuced ( handle , segno , recno , column , nvals , dvals , isnull ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( nvals ) dvals = stypes . toDoubleVector ( dvals ) isnull = ctypes . c_int ( i...
Update a double precision column entry in a specified EK record .
247,574
def ekucei ( handle , segno , recno , column , nvals , ivals , isnull ) : handle = ctypes . c_int ( handle ) segno = ctypes . c_int ( segno ) recno = ctypes . c_int ( recno ) column = stypes . stringToCharP ( column ) nvals = ctypes . c_int ( nvals ) ivals = stypes . toIntVector ( ivals ) isnull = ctypes . c_int ( isnu...
Update an integer column entry in a specified EK record .
247,575
def el2cgv ( ellipse ) : assert ( isinstance ( ellipse , stypes . Ellipse ) ) center = stypes . emptyDoubleVector ( 3 ) smajor = stypes . emptyDoubleVector ( 3 ) sminor = stypes . emptyDoubleVector ( 3 ) libspice . el2cgv_c ( ctypes . byref ( ellipse ) , center , smajor , sminor ) return stypes . cVectorToPython ( cent...
Convert an ellipse to a center vector and two generating vectors . The selected generating vectors are semi - axes of the ellipse .
247,576
def elemc ( item , inset ) : assert isinstance ( inset , stypes . SpiceCell ) item = stypes . stringToCharP ( item ) return bool ( libspice . elemc_c ( item , ctypes . byref ( inset ) ) )
Determine whether an item is an element of a character set .
247,577
def elemd ( item , inset ) : assert isinstance ( inset , stypes . SpiceCell ) assert inset . dtype == 1 item = ctypes . c_double ( item ) return bool ( libspice . elemd_c ( item , ctypes . byref ( inset ) ) )
Determine whether an item is an element of a double precision set .
247,578
def elemi ( item , inset ) : assert isinstance ( inset , stypes . SpiceCell ) assert inset . dtype == 2 item = ctypes . c_int ( item ) return bool ( libspice . elemi_c ( item , ctypes . byref ( inset ) ) )
Determine whether an item is an element of an integer set .
247,579
def eqstr ( a , b ) : return bool ( libspice . eqstr_c ( stypes . stringToCharP ( a ) , stypes . stringToCharP ( b ) ) )
Determine whether two strings are equivalent .
247,580
def erract ( op , lenout , action = None ) : if action is None : action = "" lenout = ctypes . c_int ( lenout ) op = stypes . stringToCharP ( op ) action = ctypes . create_string_buffer ( str . encode ( action ) , lenout . value ) actionptr = ctypes . c_char_p ( ctypes . addressof ( action ) ) libspice . erract_c ( op ...
Retrieve or set the default error action . spiceypy sets the default error action to report on init .
247,581
def errch ( marker , string ) : marker = stypes . stringToCharP ( marker ) string = stypes . stringToCharP ( string ) libspice . errch_c ( marker , string )
Substitute a character string for the first occurrence of a marker in the current long error message .
247,582
def errdev ( op , lenout , device ) : lenout = ctypes . c_int ( lenout ) op = stypes . stringToCharP ( op ) device = ctypes . create_string_buffer ( str . encode ( device ) , lenout . value ) deviceptr = ctypes . c_char_p ( ctypes . addressof ( device ) ) libspice . errdev_c ( op , lenout , deviceptr ) return stypes . ...
Retrieve or set the name of the current output device for error messages .
247,583
def errdp ( marker , number ) : marker = stypes . stringToCharP ( marker ) number = ctypes . c_double ( number ) libspice . errdp_c ( marker , number )
Substitute a double precision number for the first occurrence of a marker found in the current long error message .
247,584
def errint ( marker , number ) : marker = stypes . stringToCharP ( marker ) number = ctypes . c_int ( number ) libspice . errint_c ( marker , number )
Substitute an integer for the first occurrence of a marker found in the current long error message .
247,585
def errprt ( op , lenout , inlist ) : lenout = ctypes . c_int ( lenout ) op = stypes . stringToCharP ( op ) inlist = ctypes . create_string_buffer ( str . encode ( inlist ) , lenout . value ) inlistptr = ctypes . c_char_p ( ctypes . addressof ( inlist ) ) libspice . errdev_c ( op , lenout , inlistptr ) return stypes . ...
Retrieve or set the list of error message items to be output when an error is detected .
247,586
def esrchc ( value , array ) : value = stypes . stringToCharP ( value ) ndim = ctypes . c_int ( len ( array ) ) lenvals = ctypes . c_int ( len ( max ( array , key = len ) ) + 1 ) array = stypes . listToCharArray ( array , xLen = lenvals , yLen = ndim ) return libspice . esrchc_c ( value , ndim , lenvals , array )
Search for a given value within a character string array . Return the index of the first equivalent array entry or - 1 if no equivalent element is found .
247,587
def et2lst ( et , body , lon , typein , timlen = _default_len_out , ampmlen = _default_len_out ) : et = ctypes . c_double ( et ) body = ctypes . c_int ( body ) lon = ctypes . c_double ( lon ) typein = stypes . stringToCharP ( typein ) timlen = ctypes . c_int ( timlen ) ampmlen = ctypes . c_int ( ampmlen ) hr = ctypes ....
Given an ephemeris epoch compute the local solar time for an object on the surface of a body at a specified longitude .
247,588
def et2utc ( et , formatStr , prec , lenout = _default_len_out ) : et = ctypes . c_double ( et ) prec = ctypes . c_int ( prec ) lenout = ctypes . c_int ( lenout ) formatStr = stypes . stringToCharP ( formatStr ) utcstr = stypes . stringToCharP ( lenout ) libspice . et2utc_c ( et , formatStr , prec , lenout , utcstr ) r...
Convert an input time from ephemeris seconds past J2000 to Calendar Day - of - Year or Julian Date format UTC .
247,589
def etcal ( et , lenout = _default_len_out ) : lenout = ctypes . c_int ( lenout ) string = stypes . stringToCharP ( lenout ) if hasattr ( et , "__iter__" ) : strings = [ ] for t in et : libspice . etcal_c ( t , lenout , string ) checkForSpiceError ( None ) strings . append ( stypes . toPythonString ( string ) ) return ...
Convert from an ephemeris epoch measured in seconds past the epoch of J2000 to a calendar string format using a formal calendar free of leapseconds .
247,590
def eul2m ( angle3 , angle2 , angle1 , axis3 , axis2 , axis1 ) : angle3 = ctypes . c_double ( angle3 ) angle2 = ctypes . c_double ( angle2 ) angle1 = ctypes . c_double ( angle1 ) axis3 = ctypes . c_int ( axis3 ) axis2 = ctypes . c_int ( axis2 ) axis1 = ctypes . c_int ( axis1 ) r = stypes . emptyDoubleMatrix ( ) libspic...
Construct a rotation matrix from a set of Euler angles .
247,591
def eul2xf ( eulang , axisa , axisb , axisc ) : assert len ( eulang ) is 6 eulang = stypes . toDoubleVector ( eulang ) axisa = ctypes . c_int ( axisa ) axisb = ctypes . c_int ( axisb ) axisc = ctypes . c_int ( axisc ) xform = stypes . emptyDoubleMatrix ( x = 6 , y = 6 ) libspice . eul2xf_c ( eulang , axisa , axisb , ax...
This routine computes a state transformation from an Euler angle factorization of a rotation and the derivatives of those Euler angles .
247,592
def exists ( fname ) : fname = stypes . stringToCharP ( fname ) return bool ( libspice . exists_c ( fname ) )
Determine whether a file exists .
247,593
def expool ( name ) : name = stypes . stringToCharP ( name ) found = ctypes . c_int ( ) libspice . expool_c ( name , ctypes . byref ( found ) ) return bool ( found . value )
Confirm the existence of a kernel variable in the kernel pool .
247,594
def frmnam ( frcode , lenout = _default_len_out ) : frcode = ctypes . c_int ( frcode ) lenout = ctypes . c_int ( lenout ) frname = stypes . stringToCharP ( lenout ) libspice . frmnam_c ( frcode , lenout , frname ) return stypes . toPythonString ( frname )
Retrieve the name of a reference frame associated with a SPICE ID code .
247,595
def furnsh ( path ) : if isinstance ( path , list ) : for p in path : libspice . furnsh_c ( stypes . stringToCharP ( p ) ) else : path = stypes . stringToCharP ( path ) libspice . furnsh_c ( path )
Load one or more SPICE kernels into a program .
247,596
def gcpool ( name , start , room , lenout = _default_len_out ) : name = stypes . stringToCharP ( name ) start = ctypes . c_int ( start ) room = ctypes . c_int ( room ) lenout = ctypes . c_int ( lenout ) n = ctypes . c_int ( ) cvals = stypes . emptyCharArray ( lenout , room ) found = ctypes . c_int ( ) libspice . gcpool...
Return the character value of a kernel variable from the kernel pool .
247,597
def gdpool ( name , start , room ) : name = stypes . stringToCharP ( name ) start = ctypes . c_int ( start ) values = stypes . emptyDoubleVector ( room ) room = ctypes . c_int ( room ) n = ctypes . c_int ( ) found = ctypes . c_int ( ) libspice . gdpool_c ( name , start , room , ctypes . byref ( n ) , ctypes . cast ( va...
Return the d . p . value of a kernel variable from the kernel pool .
247,598
def georec ( lon , lat , alt , re , f ) : lon = ctypes . c_double ( lon ) lat = ctypes . c_double ( lat ) alt = ctypes . c_double ( alt ) re = ctypes . c_double ( re ) f = ctypes . c_double ( f ) rectan = stypes . emptyDoubleVector ( 3 ) libspice . georec_c ( lon , lat , alt , re , f , rectan ) return stypes . cVectorT...
Convert geodetic coordinates to rectangular coordinates .
247,599
def getelm ( frstyr , lineln , lines ) : frstyr = ctypes . c_int ( frstyr ) lineln = ctypes . c_int ( lineln ) lines = stypes . listToCharArrayPtr ( lines , xLen = lineln , yLen = 2 ) epoch = ctypes . c_double ( ) elems = stypes . emptyDoubleVector ( 10 ) libspice . getelm_c ( frstyr , lineln , lines , ctypes . byref (...
Given a the lines of a two - line element set parse the lines and return the elements in units suitable for use in SPICE software .