Changeset 7ecb2a8 for python


Ignore:
Timestamp:
05/03/19 10:41:40 (6 years ago)
Author:
Thomas Uram <turam@…>
Branches:
pympi
Children:
1ef52ae
Parents:
7889dc4
git-author:
Thomas Uram <turam@…> (05/03/19 10:41:40)
git-committer:
Thomas Uram <turam@…> (05/03/19 10:41:40)
Message:

intermediate

Location:
python
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • python/genericio.py

    r7889dc4 r7ecb2a8  
    5252 
    5353libpygio.get_variable_type.restype=ct.c_int 
    54 libpygio.get_variable_type.argtypes=[ct.c_char_p,ct.c_char_p] 
     54libpygio.get_variable_type.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p] 
    5555 
    5656libpygio.get_variable_field_count.restype=ct.c_int 
    57 libpygio.get_variable_field_count.argtypes=[ct.c_char_p,ct.c_char_p] 
     57libpygio.get_variable_field_count.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p] 
    5858 
    5959libpygio.read_gio_uint16.restype=None 
    60 libpygio.read_gio_uint16.argtypes=[ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_uint16),ct.c_int] 
     60libpygio.read_gio_uint16.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_uint16),ct.c_int] 
    6161 
    6262libpygio.read_gio_int32.restype=None 
    63 libpygio.read_gio_int32.argtypes=[ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_int),ct.c_int] 
     63libpygio.read_gio_int32.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_int),ct.c_int] 
    6464 
    6565libpygio.read_gio_int64.restype=None 
    66 libpygio.read_gio_int64.argtypes=[ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_int64),ct.c_int] 
     66libpygio.read_gio_int64.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_int64),ct.c_int] 
    6767 
    6868libpygio.read_gio_float.restype=None 
    69 libpygio.read_gio_float.argtypes=[ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_float),ct.c_int] 
     69libpygio.read_gio_float.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_float),ct.c_int] 
    7070 
    7171libpygio.read_gio_double.restype=None 
    72 libpygio.read_gio_double.argtypes=[ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_double),ct.c_int] 
     72libpygio.read_gio_double.argtypes=[ct.c_int,ct.c_char_p,ct.c_char_p,ct.POINTER(ct.c_double),ct.c_int] 
    7373 
    7474libpygio.inspect_gio.restype=None 
    75 libpygio.inspect_gio.argtypes=[ct.c_char_p] 
     75libpygio.inspect_gio.argtypes=[ct.c_int,ct.c_char_p] 
    7676 
    7777def gio_read_(comm,file_name,var_name): 
  • python/lib/gio.cxx

    rd409b8c r7ecb2a8  
    4343#include <iostream> 
    4444 
    45   void read_gio_float(const MPI_Comm &C, char* file_name, char* var_name, float* data, int field_count){ 
     45  void read_gio_float(const MPI_Comm C, char* file_name, char* var_name, float* data, int field_count){ 
    4646    read_gio<float>(C, file_name,var_name,data,field_count); 
    4747  } 
    48   void read_gio_double(const MPI_Comm &C, char* file_name, char* var_name, double* data, int field_count){ 
     48  void read_gio_double(const MPI_Comm C, char* file_name, char* var_name, double* data, int field_count){ 
    4949    read_gio<double>(C, file_name,var_name,data,field_count); 
    5050  } 
    51   void read_gio_uint16(const MPI_Comm &C, char* file_name, char* var_name, uint16_t* data, int field_count){ 
     51  void read_gio_uint16(const MPI_Comm C, char* file_name, char* var_name, uint16_t* data, int field_count){ 
    5252    read_gio<uint16_t>(C, file_name,var_name,data,field_count); 
    5353  } 
    54   void read_gio_int32(const MPI_Comm &C, char* file_name, char* var_name, int* data, int field_count){ 
     54  void read_gio_int32(const MPI_Comm C, char* file_name, char* var_name, int* data, int field_count){ 
    5555    read_gio<int>(C, file_name,var_name,data,field_count); 
    5656  } 
    57   void read_gio_int64(const MPI_Comm &C, char* file_name, char* var_name, int64_t* data, int field_count){ 
     57  void read_gio_int64(const MPI_Comm C, char* file_name, char* var_name, int64_t* data, int field_count){ 
    5858    read_gio<int64_t>(C, file_name,var_name,data,field_count); 
    5959  } 
    6060   
    61   int64_t get_elem_num(const MPI_Comm &C, char* file_name){ 
     61  int64_t get_elem_num(const MPI_Comm C, char* file_name){ 
    6262    gio::GenericIO reader(C, file_name); 
    6363    reader.openAndReadHeader(gio::GenericIO::MismatchAllowed); 
     
    7070  } 
    7171 
    72   var_type get_variable_type(const MPI_Comm &C, char* file_name,char* var_name){ 
     72  var_type get_variable_type(const MPI_Comm C, char* file_name,char* var_name){ 
    7373   gio::GenericIO reader(C, file_name); 
    7474   std::vector<gio::GenericIO::VariableInfo> VI; 
     
    9898  } 
    9999 
    100   int get_variable_field_count(const MPI_Comm &C, char* file_name,char* var_name){ 
     100  int get_variable_field_count(const MPI_Comm C, char* file_name,char* var_name){ 
    101101   gio::GenericIO reader(C, file_name); 
    102102   std::vector<gio::GenericIO::VariableInfo> VI; 
     
    115115 
    116116#ifndef GENERICIO_NO_MPI 
    117 extern "C" void inspect_gio(const MPI_Comm &C, char* file_name){ 
     117extern "C" void inspect_gio(const MPI_Comm C, char* file_name){ 
    118118  gio::GenericIO reader(C, file_name); 
    119119#else 
    120 extern "C" void inspect_gio(const MPI_Comm &C, char* file_name){ 
     120extern "C" void inspect_gio(const MPI_Comm C, char* file_name){ 
    121121  gio::GenericIO reader(C, file_name); 
    122122#endif 
  • python/lib/gio.h

    r7889dc4 r7ecb2a8  
    4747template <class T> 
    4848#ifndef GENERICIO_NO_MPI 
    49 void read_gio(const MPI_Comm &C, char* file_name, std::string var_name, T*& data, int field_count){ 
     49void read_gio(const MPI_Comm C, char* file_name, std::string var_name, T*& data, int field_count){ 
    5050  gio::GenericIO reader(C, file_name); 
    5151#else 
     
    7474  reader.close(); 
    7575} 
    76 extern "C" int64_t get_elem_num(const MPI_Comm &c, char* file_name); 
     76extern "C" int64_t get_elem_num(const MPI_Comm C, char* file_name); 
    7777 
    78 extern "C" void read_gio_float (const MPI_Comm &C, char* file_name, char* var_name, float* data, int field_count); 
    79 extern "C" void read_gio_double(const MPI_Comm &C, char* file_name, char* var_name, double* data, int field_count); 
    80 extern "C" void read_gio_uint16 (const MPI_Comm &C, char* file_name, char* var_name, uint16_t* data, int field_count);  
    81 extern "C" void read_gio_int32 (const MPI_Comm &C, char* file_name, char* var_name, int* data, int field_count);  
    82 extern "C" void read_gio_int64 (const MPI_Comm &C, char* file_name, char* var_name, int64_t* data, int field_count); 
     78extern "C" void read_gio_float (const MPI_Comm C, char* file_name, char* var_name, float* data, int field_count); 
     79extern "C" void read_gio_double(const MPI_Comm C, char* file_name, char* var_name, double* data, int field_count); 
     80extern "C" void read_gio_uint16 (const MPI_Comm C, char* file_name, char* var_name, uint16_t* data, int field_count);  
     81extern "C" void read_gio_int32 (const MPI_Comm C, char* file_name, char* var_name, int* data, int field_count);  
     82extern "C" void read_gio_int64 (const MPI_Comm C, char* file_name, char* var_name, int64_t* data, int field_count); 
    8383enum var_type{ 
    8484  float_type=0, 
     
    9090  var_not_found=10 
    9191}; 
    92 extern "C" var_type get_variable_type(const MPI_Comm &C, char* file_name,char* var_name); 
    93 extern "C" int get_variable_field_count(const MPI_Comm &C, char* file_name,char* var_name); 
    94 extern "C" void inspect_gio(const MPI_Comm &C, char* file_name); 
     92extern "C" var_type get_variable_type(const MPI_Comm C, char* file_name,char* var_name); 
     93extern "C" int get_variable_field_count(const MPI_Comm C, char* file_name,char* var_name); 
     94extern "C" void inspect_gio(const MPI_Comm C, char* file_name); 
Note: See TracChangeset for help on using the changeset viewer.