@@ -992,8 +992,8 @@ cdef class Variable:
992
992
993
993
This method call is the same as method :meth:`Variable.put_varn_all`,
994
994
except it is an independent call and can only be called in the
995
- independent I/O mode. Please refer to :meth:`Variable.put_varn ` for its
996
- argument usage.
995
+ independent I/O mode. Please refer to :meth:`Variable.put_varn_all ` for
996
+ its argument usage.
997
997
"""
998
998
self ._put_varn(data, num, starts, counts, bufcount = bufcount,
999
999
buftype = buftype, collective = False )
@@ -1005,22 +1005,22 @@ cdef class Variable:
1005
1005
This method call is the nonblocking counterpart of
1006
1006
:meth:`Variable.put_varn`. The syntax is the same as
1007
1007
:meth:`Variable.put_varn`. For the argument usage, please refer to
1008
- method :meth:`Variable.put_varn `. This method returns a request ID
1009
- that can be used in :meth:`File.wait ` or :meth:`File.wait_all `. The
1010
- posted write request may not be committed until :meth:`File.wait ` or
1011
- :meth:`File.wait_all ` is called.
1008
+ method :meth:`Variable.put_varn_all `. This method returns a request ID
1009
+ that can be used in :meth:`File.wait_all ` or :meth:`File.wait `. The
1010
+ posted write request may not be committed until :meth:`File.wait_all ` or
1011
+ :meth:`File.wait ` is called.
1012
1012
1013
1013
.. note::
1014
1014
Unlike :meth:`Variable.put_varn`, the posted nonblocking write
1015
1015
requests may not be committed to the file until the time of calling
1016
- :meth:`File.wait ` or :meth:`File.wait_all `. Users should not
1016
+ :meth:`File.wait_all ` or :meth:`File.wait `. Users should not
1017
1017
alter the contents of the write buffer once the request is posted
1018
- until the :meth:`File.wait ` or :meth:`File.wait_all ` is
1018
+ until the :meth:`File.wait_all ` or :meth:`File.wait ` is
1019
1019
returned. Any change to the buffer contents in between will result
1020
1020
in unexpected error.
1021
1021
1022
1022
:return: The request ID, which can be used in a successive call to
1023
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
1023
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
1024
1024
of the nonblocking operation.
1025
1025
:rtype: int
1026
1026
"""
@@ -1033,22 +1033,22 @@ cdef class Variable:
1033
1033
1034
1034
This method call is the nonblocking, buffered counterpart of
1035
1035
:meth:`Variable.put_varn`. For the argument usage, please refer to
1036
- method :meth:`Variable.put_varn `. This method returns a request ID
1037
- that can be used in :meth:`File.wait ` or :meth:`File.wait_all `. The
1038
- posted write request may not be committed until :meth:`File.wait` or
1039
- :meth:`File.wait_all ` is called.
1036
+ method :meth:`Variable.put_varn_all `. This method returns a request ID
1037
+ that can be used in :meth:`File.wait_all ` or :meth:`File.wait `. The
1038
+ posted write request may not be committed until :meth:`File.wait_all`
1039
+ or :meth:`File.wait ` is called.
1040
1040
1041
1041
.. note::
1042
1042
Unlike :meth:`Variable.iput_varn`, the write data is buffered
1043
1043
(cached) internally by PnetCDF and will be flushed to the file at
1044
- the time of calling :meth:`File.wait ` or :meth:`File.wait_all `.
1044
+ the time of calling :meth:`File.wait_all ` or :meth:`File.wait `.
1045
1045
Once the call to this method returns, the caller is free to change
1046
1046
the contents of write buffer. Prior to calling this method, make
1047
1047
sure :meth:`File.attach_buff` is called to allocate an internal
1048
1048
buffer for accommodating the write requests.
1049
1049
1050
1050
:return: The request ID, which can be used in a successive call to
1051
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
1051
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
1052
1052
of the nonblocking operation.
1053
1053
:rtype: int
1054
1054
"""
@@ -1331,7 +1331,7 @@ cdef class Variable:
1331
1331
1332
1332
Method to write in parallel to the netCDF variable in the independent
1333
1333
I/O mode. For the argument usage, please refer to method
1334
- :meth:`Variable.put_var `. The only difference is this method is a
1334
+ :meth:`Variable.put_var_all `. The only difference is this method is a
1335
1335
independent operation.
1336
1336
1337
1337
:Operational mode: This method must be called while the file is in
@@ -1852,7 +1852,7 @@ cdef class Variable:
1852
1852
1853
1853
Method to read in parallel from the netCDF variable in the independent
1854
1854
I/O mode. For the argument usage, please refer to method
1855
- :meth:`Variable.get_var `. The only difference is this method is a
1855
+ :meth:`Variable.get_var_all `. The only difference is this method is a
1856
1856
independent operation.
1857
1857
1858
1858
:Operational mode: This method must be called while the file is in
@@ -1871,13 +1871,13 @@ cdef class Variable:
1871
1871
else :
1872
1872
raise ValueError (" Invalid input arguments for get_var" )
1873
1873
1874
- def get_varn (self , data , num , starts , counts = None , bufcount = None , buftype = None ):
1874
+ def get_varn_all (self , data , num , starts , counts = None , bufcount = None , buftype = None ):
1875
1875
"""
1876
- get_varn (self, data, num, starts, counts=None, bufcount=None, buftype=None)
1876
+ get_varn_all (self, data, num, starts, counts=None, bufcount=None, buftype=None)
1877
1877
1878
1878
Method to read multiple subarrays of a netCDF variables from the file.
1879
- This an independent I/O call and can only be called when the file is in
1880
- the independent I/O mode. This method is equivalent to making multiple
1879
+ This a collective I/O call and can only be called when the file is in
1880
+ the collective I/O mode. This method is equivalent to making multiple
1881
1881
calls to :meth:`Variable.get_var`. Note, combining multiple `get_var`
1882
1882
calls into one can achieve a better performance.
1883
1883
@@ -1974,19 +1974,19 @@ cdef class Variable:
1974
1974
1975
1975
"""
1976
1976
return self ._get_varn(data, num, starts, counts, bufcount = bufcount,
1977
- buftype = buftype, collective = False )
1977
+ buftype = buftype, collective = True )
1978
1978
1979
- def get_varn_all (self , data , num , starts , counts = None , bufcount = None , buftype = None ):
1979
+ def get_varn (self , data , num , starts , counts = None , bufcount = None , buftype = None ):
1980
1980
"""
1981
- get_varn_all (self, data, num, starts, counts=None, bufcount=None, buftype=None)
1981
+ get_varn (self, data, num, starts, counts=None, bufcount=None, buftype=None)
1982
1982
1983
- This method call is the same as method :meth:`Variable.get_varn `,
1984
- except it is collective and can only be called while the file in the
1985
- collective I/O mode. Please refer to :meth:`Variable.get_varn` for
1986
- its argument usage.
1983
+ This method call is the same as method :meth:`Variable.get_varn_all `,
1984
+ except it is an independent call and can only be called while the file
1985
+ in the independent I/O mode. Please refer to
1986
+ :meth:`Variable.get_varn_all` for its argument usage.
1987
1987
"""
1988
1988
return self ._get_varn(data, num, starts, counts, bufcount = bufcount,
1989
- buftype = buftype, collective = True )
1989
+ buftype = buftype, collective = False )
1990
1990
1991
1991
def _get (self ,start ,count ,stride ):
1992
1992
""" Private method to retrieve data from a netCDF variable"""
@@ -2344,24 +2344,25 @@ cdef class Variable:
2344
2344
2345
2345
Method to post a nonblocking, buffered write request to write to the
2346
2346
netCDF variable. The syntax is the same as :meth:`Variable.put_var`.
2347
- For the argument usage, please refer to :meth:`Variable.put_var`. This
2348
- method returns a request ID that can be used in :meth:`File.wait` or
2349
- :meth:`File.wait_all`. The posted write request may not be committed
2350
- until :meth:`File.wait` or :meth:`File.wait_all` is called.
2347
+ For the argument usage, please refer to :meth:`Variable.put_var_all`.
2348
+ This method returns a request ID that can be used in
2349
+ :meth:`File.wait_all` or :meth:`File.wait`. The posted write request
2350
+ may not be committed until :meth:`File.wait_all` or :meth:`File.wait`
2351
+ is called.
2351
2352
2352
2353
.. note:: Note that this method requires a numpy array (`data`) as a
2353
2354
write buffer from caller prepared for writing returned array values
2354
- when :meth:`File.wait ` or :meth:`File.wait_all ` is called.
2355
+ when :meth:`File.wait_all ` or :meth:`File.wait ` is called.
2355
2356
Unlike :meth:`Variable.iput_var`, the write data is buffered
2356
2357
(cached) internally by PnetCDF and will be flushed to the file at
2357
- the time of calling :meth:`File.wait ` or :meth:`File.wait_all `.
2358
+ the time of calling :meth:`File.wait_all ` or :meth:`File.wait `.
2358
2359
Once the call to this method returns, the caller is free to change
2359
2360
the contents of write buffer. Prior to calling this method, make
2360
2361
sure :meth:`File.attach_buff` is called to allocate an internal
2361
2362
buffer for accommodating the write requests.
2362
2363
2363
2364
:return: The request ID, which can be used in a successive call to
2364
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
2365
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
2365
2366
of the nonblocking operation.
2366
2367
:rtype: int
2367
2368
@@ -2388,22 +2389,22 @@ cdef class Variable:
2388
2389
2389
2390
Method to post a nonblocking request to write to the netCDF variable.
2390
2391
The syntax is the same as :meth:`Variable.put_var`. For the argument
2391
- usage, please refer to :meth:`Variable.put_var `. This method returns a
2392
- request ID that can This method returns a request ID that can be used
2393
- in :meth:`File.wait ` or :meth:`File.wait_all `. The posted write request
2394
- may not be committed until :meth:`File.wait ` or :meth:`File.wait_all`
2395
- is called.
2392
+ usage, please refer to :meth:`Variable.put_var_all `. This method
2393
+ returns a request ID that can This method returns a request ID that can
2394
+ be used in :meth:`File.wait_all ` or :meth:`File.wait `. The posted write
2395
+ request may not be committed until :meth:`File.wait_all ` or
2396
+ :meth:`File.wait` is called.
2396
2397
2397
2398
.. note:: Note that this method requires a numpy array (`data`) as a
2398
2399
write buffer from caller prepared for writing returned array values
2399
- when :meth:`File.wait ` or :meth:`File.wait_all ` is called.
2400
- Users should not alter the contents of the write buffer once the
2401
- request is posted until the :meth:`File.wait ` or
2402
- :meth:`File.wait_all` is returned. Any change to the buffer
2403
- contents in between will result in unexpected error.
2400
+ when :meth:`File.wait_all ` or :meth:`File.wait ` is called. Users
2401
+ should not alter the contents of the write buffer once the request
2402
+ is posted until the :meth:`File.wait_all ` or :meth:`File.wait` is
2403
+ returned. Any change to the buffer contents in between will result
2404
+ in unexpected error.
2404
2405
2405
2406
:return: The request ID, which can be used in a successive call to
2406
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
2407
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
2407
2408
of the nonblocking operation.
2408
2409
:rtype: int
2409
2410
@@ -2538,22 +2539,22 @@ cdef class Variable:
2538
2539
This method call is the nonblocking counterpart of
2539
2540
:meth:`Variable.get_varn`. The syntax is the same as
2540
2541
:meth:`Variable.get_varn`. For the argument usage, please refer to
2541
- method :meth:`Variable.get_varn `. This method returns a request ID
2542
- that can be used in :meth:`File.wait ` or :meth:`File.wait_all `. The
2543
- posted write request may not be committed until :meth:`File.wait` or
2544
- :meth:`File.wait_all ` is called.
2542
+ method :meth:`Variable.get_varn_all `. This method returns a request ID
2543
+ that can be used in :meth:`File.wait_all ` or :meth:`File.wait `. The
2544
+ posted write request may not be committed until :meth:`File.wait_all`
2545
+ or :meth:`File.wait ` is called.
2545
2546
2546
2547
.. note::
2547
2548
Unlike :meth:`Variable.get_varn`, the posted nonblocking read
2548
2549
requests may not be committed until the time of calling
2549
- :meth:`File.wait ` or :meth:`File.wait_all `. Users should not
2550
+ :meth:`File.wait_all ` or :meth:`File.wait `. Users should not
2550
2551
alter the contents of the read buffer once the request is posted
2551
- until the :meth:`File.wait ` or :meth:`File.wait_all ` is
2552
+ until the :meth:`File.wait_all ` or :meth:`File.wait ` is
2552
2553
returned. Any change to the buffer contents in between will result
2553
2554
in unexpected error.
2554
2555
2555
2556
:return: The request ID, which can be used in a successive call to
2556
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
2557
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
2557
2558
of the nonblocking operation.
2558
2559
:rtype: int
2559
2560
"""
@@ -2646,20 +2647,20 @@ cdef class Variable:
2646
2647
2647
2648
Method to post a nonblocking request to read from the netCDF variable.
2648
2649
The syntax is the same as :meth:`Variable.get_var`. For the argument
2649
- usage, please refer to :meth:`Variable.get_var `. This method returns a
2650
- request ID that can be used in :meth:`File.wait ` or
2651
- :meth:`File.wait_all `. The posted read request may not be committed
2652
- until :meth:`File.wait ` or :meth:`File.wait_all ` is called.
2650
+ usage, please refer to :meth:`Variable.get_var_all `. This method
2651
+ returns a request ID that can be used in :meth:`File.wait_all ` or
2652
+ :meth:`File.wait `. The posted read request may not be committed until
2653
+ :meth:`File.wait_all ` or :meth:`File.wait ` is called.
2653
2654
2654
2655
.. note:: Note that this method requires a empty array (`data`) as a
2655
2656
read buffer from caller prepared for storing returned array values
2656
- when :meth:`File.wait ` or :meth:`File.wait_all ` is called. User
2657
+ when :meth:`File.wait_all ` or :meth:`File.wait ` is called. User
2657
2658
is expected to retain this buffer array handler (the numpy
2658
2659
variable) until the read buffer is committed and the transaction is
2659
2660
completed.
2660
2661
2661
2662
:return: The request ID, which can be used in a successive call to
2662
- :meth:`File.wait ` or :meth:`File.wait_all ` for the completion
2663
+ :meth:`File.wait_all ` or :meth:`File.wait ` for the completion
2663
2664
of the nonblocking operation.
2664
2665
:rtype: int
2665
2666
0 commit comments