Skip to content

Commit 1421a59

Browse files
authored
Docstanya (#297)
* merge docs * add requirements.txt * remove cdat_info * remote cdat_info * fix latex_logo png * pin pyopenssl to 17.2.0 due to myproxyclient failure in py3 * update TOC * work on tables and setup * try to force jquery 3.1 * just copy js script in _static * add highlight python * add sample dataset page * add sample dataset page * work on tables for cdms_2.rst * continue cdms2 documentations * update cdms2 tables * update sections * update table * finish chapter 2 * fix litteral error * unlink .dodsrc for cdscan * First changes from Tanya * some change in chapter 1 and 2 * some changes in Chapter 2 * fix tables * Some changes to Chapter 2 * Some Changes to Chapter 2 * Some changes made to Chapters 1, 2 and 4 * Some changes to Chapter 2 * Some Changes made to Chapter 2 * Some changes to Chapters 2, 3 and 4 * Some changes made to 1 through Appendix * Some Changes made to Chapter 2 * Some Changes to Chapters 1, 2, 3, 6 and Appendix * Some changes made to Chapters 1 thru 7 and appendix * Some changes to Chpaters 1, 2 and 3 * Changes made to Chapters 1, 4, 5 and Appendix * Some changes to Chapter 2 and 4 * Some Changes to Images, Chapter 3 and Appendix * update logo * add my logo * fix chapter 1 test * Some changes made to Chapters 2, 3 and 5 * Some Changes to Chapters 1 and 2 * Some changes to Appendix * update banner/footer and version * Some Changes to Chapters 1, 2, 3 and appendix * change u to uold in example * Some changes to Chapters 2, 4, 5 and 6 * Some changes to Regrid 2, Lib, esmf, gsRegrid and horizontal * Changes made to Chapters 1-7 and sample data * fix API documentation * rename regrid2 directory and delete print message * add module API files * add future and mock requirements * get cwd for readthedocs * Changes made to API * Changes made to API * Changes made to API * Changes to API * test rtd with mock * add future for readthedocs * create git.py in ../.. * add esmf * add print statements for regrid2 * add print for libregrid2 * restore regrid2.Lib for readthedocs * add mock modules * add git.py * try with new mock list * force git.py * force git.py * try readthedocs.yml file * fix readthedocs maping file * change type pdb to pdf * typo requirements.yml * add dependencies * add dependencies and change conf.yml * change API.rst and other rst files * Changes to API * UVCDAT_ANONYMOUS_LOG set to false * check if git.py is there * add gcc to environment.yml * try docker environment.yml * remove git.py * chage Libregrid to regrid2 * revert * revert * add cdms2 class * delet cdms2 class * delet cdms2 class * change conf.py os.path * Changes to API * Changes made to API * Changes to API * Changes made to API * Changes to API * Changes made to API * Changes made to API * Changes to API * Changes to API * Changes made to API * Changes made to API * Changes made to API * push latest rst files * Changes made to API * Made some changes to API * update documentations * Changes made to API * Changes made to API * Changes made to API * Changes made to Section 2 and API * Changes made to Section 2 * Changes made to Chapter 2 * Changes made to Section 2 * Changes made to Chapters 2, 3, 4,5 and 6 * Changes made to Sections 2, 4, 7 and Appendix * Changes made to Chapter 6 and Appendix * Changes made to Section 2 * update summary table for API * add generated files * Changes made to al sections * Changes made to Section 2 and API * Changes made to 2 and API * Made changes to sections 1 and 2 * Issue#231 (#232) * fix #225 passing transiant variable as axis * Fix macOSX * fix ESMF and NPY_STRING * fix data._mask comparison for numpy 1.14 * failing test from vcs added here (#234) * failing test from vcs added here * ok test passes again * reverted for now * commented out test for @durack1 * Cdmsdocsmerge (#223) * First cdms2 documentation revamp * latest changes * add new files and work on avariable documentations * fix index order * revamp documentation * Fixing cdms documentation (docstrings) * update documentation * continue to work on docs * sphinx doctest in manual.rst * chapter 1 continu * add requirments.txt for read-the-doc * move requirements.txt into docs dir * add requirements * Chapter 2 * add chapter 3 * finish chapter 3 started chapter 4 * flake8 python files * chapter 4 regridding * cdms_4 doctest * add other chapters * finish chapter 4 * add chapter 5 * add chapter 6 * cdms chapter 6 * fix TOC * add chapter 7 and appendix * merge docs * add requirements.txt * remove cdat_info * remote cdat_info * fix latex_logo png * pin pyopenssl to 17.2.0 due to myproxyclient failure in py3 * update TOC * work on tables and setup * try to force jquery 3.1 * just copy js script in _static * add highlight python * add sample dataset page * add sample dataset page * work on tables for cdms_2.rst * continue cdms2 documentations * update cdms2 tables * update sections * update table * finish chapter 2 * fix litteral error * unlink .dodsrc for cdscan * First changes from Tanya * some change in chapter 1 and 2 * some changes in Chapter 2 * fix tables * Some changes to Chapter 2 * Some Changes to Chapter 2 * Some changes made to Chapters 1, 2 and 4 * Some changes to Chapter 2 * Some Changes made to Chapter 2 * Some changes to Chapters 2, 3 and 4 * Some changes made to 1 through Appendix * Some Changes made to Chapter 2 * Some Changes to Chapters 1, 2, 3, 6 and Appendix * Some changes made to Chapters 1 thru 7 and appendix * Some changes to Chpaters 1, 2 and 3 * Changes made to Chapters 1, 4, 5 and Appendix * Some changes to Chapter 2 and 4 * Some Changes to Images, Chapter 3 and Appendix * update logo * add my logo * fix chapter 1 test * Fix python3 slice issue(setitem) and flake8 (#243) * fix python 3 aggregation issue and flake8 (#244) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * Netcdf46 (#249) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * Revert "Netcdf46 (#249)" (#250) This reverts commit a9e29ea. * Netcdf46 (#251) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * inverse dodsrc and curl commands * move unlink above cdscan test * fix ESGF test * add new dodsrc files * create dodsrc on-demand * put back tests for unstable * Netcdf46 (#252) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * inverse dodsrc and curl commands * move unlink above cdscan test * fix ESGF test * add new dodsrc files * create dodsrc on-demand * put back tests for unstable * instal anaconda-client before calling conda-upload * Changes made to API * Made some changes to API * Changes made to API * Changes made to API * Changes made to API * Changes made to Section 2 and API * Changes made to Section 2 * Changes made to Chapter 2 * Changes made to Section 2 * Changes made to Chapters 2, 3, 4,5 and 6 * Changes made to Sections 2, 4, 7 and Appendix * Changes made to Chapter 6 and Appendix * Changes made to Section 2 * Changes made to al sections * Changes made to Section 2 and API * Changes made to 2 and API * Made changes to sections 1 and 2 * Issue#231 (#232) * fix #225 passing transiant variable as axis * Fix macOSX * fix ESMF and NPY_STRING * fix data._mask comparison for numpy 1.14 * Fix python3 slice issue(setitem) and flake8 (#243) * fix python 3 aggregation issue and flake8 (#244) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * Netcdf46 (#249) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * Revert "Netcdf46 (#249)" (#250) This reverts commit a9e29ea. * Netcdf46 (#251) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * inverse dodsrc and curl commands * move unlink above cdscan test * fix ESGF test * add new dodsrc files * create dodsrc on-demand * put back tests for unstable * Netcdf46 (#252) * Fix python3 slice issue(setitem) and flake8 * update to libnetcdf 4.6 * try circleci unstable label * try version 2 circleci * try version 2 circleci * change workflow name * change cdtime to cdms * add certificate to circleci * add fix conda-upload in circleci 2.0 * update prep_for_build version * fix curl command * fix cicleci for cdms * use unstable channel change uvcdat for cdat * build cdms on circleci 2.0 * fix circleci config.yml * change Users/distiler to /Users/denisnadeau * add gcc_linux * add LDSHARED for linux * disable cert and py results * add gcc_linux-64 * change cdscan link * fix myproxy * add esmf and esmpy to py3 env * inverse dodsrc and curl commands * move unlink above cdscan test * fix ESGF test * add new dodsrc files * create dodsrc on-demand * put back tests for unstable * instal anaconda-client before calling conda-upload * Fix table titles * Change made to Section 4 * fix bindex issue in hgrid * Changes to all * Corrections made to API Lib * Changes to API * fix ascii art * Changes to Sections 2, 4 and 5 * Changes made to all * Changes made to Sections 2, 6 and Appendix * Changes made to Section 2 * Changes made to Section 2 * Changes made to Section 2 and 5 * Changes to Sections 2, 6 and 7 * Changes to API * Changes made to API * Made Changes to API * Changes made to API * Changes made to Section 4 and 7 * Changes made to API * Changes made to API * Revisit run tests (#262) * migrate run_tests.py to use TestRunnerBase * remove accidentally added tests/coverage.json * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * revisit run_tests.py * add cacert.pem in run_tests.py when running cdms test within the lab * add cacert.pem in run_tests.py when running cdms test within the lab * add cacert.pem in run_tests.py when running cdms test within the lab * add cacert.pem in run_tests.py when running cdms test within the lab - rerun tests * add cacert.pem in run_tests.py when running cdms test within the lab - remove install from -c cdat/label/unstable * put back -c cdat/label/unstable * fix Axis.py * update documentation * fix environment dependencies * add/remote generated files * try to fix API.rst * add regrid2 to docs * Changes made to API * fix space with parameters * fix readthedocs using numpydoc * update environment * fix some autodocs * add hgrid * Changes made to API * Changes made to API * fix avariable bad location methods * Changes to Appendix and API * Changes to Chapter 1 and 2 * Changes made to Section 2 * Changes made to Section 2 * Changes made to Section 2 * Changes to sections 1, 2, 3 and 4 * Changes to section 2 * Changes made to entire docuemnt * Changes to Section 1 and 2 * Changes made to Section 2 * Changes made to Sections 2 thru 6 * Changes made to Chapters 3 and 6 * add jupyter notebook * Changes to all * Changes to Jupyter Notebooks * Changes to all * update documentation for version 3.1.0 * merge documentations * change banner and sidebar colors * Changes to API * fix style sheet * Changes to API * Changes to API * Changes to API and Sections * Changes to all * will this fix master? (#292) * Changes to Sections 1 and 2 * fix cdtime and scripts * trigger read-the-docs * fix more cdtime doc issues * fix typo Default-Calendar * fix conflicts * pass flake8
1 parent 5a83dd4 commit 1421a59

File tree

14 files changed

+73
-93
lines changed

14 files changed

+73
-93
lines changed

Lib/MV2.py

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,6 @@ def __init__(self, mafunc):
7979
"""
8080
Parameters
8181
----------
82-
8382
var_unary_operation(mafunc)
8483
8584
mafunc is an numpy.ma masked_unary_function.
@@ -124,7 +123,6 @@ def commonDomain(a, b, omit=None):
124123
125124
commonDomain(a,b)
126125
tests that the domains of variables/arrays a and b are equal,
127-
and
128126
129127
Returns
130128
-------
@@ -146,14 +144,15 @@ def commonDomain(a, b, omit=None):
146144

147145

148146
def commonAxes(a, bdom, omit=None):
149-
"""Helper function for commonDomain.
147+
"""
148+
Helper function for commonDomain.
150149
151150
Parameters
152151
----------
153-
154-
'a' is a variable or array,
155-
156-
'b' is an axislist or None.
152+
'a':
153+
is a variable or array,
154+
'b':
155+
is an axislist or None.
157156
"""
158157
if isinstance(a, AbstractVariable) and bdom is not None:
159158
adom = a.getAxisList()
@@ -272,7 +271,6 @@ def __init__(self, mafunc):
272271
----------
273272
274273
var_binary_operation(mafunc)
275-
276274
mafunc is an numpy.ma masked_binary_function.
277275
"""
278276
self.mafunc = mafunc
@@ -935,13 +933,14 @@ def outer(self, a, b):
935933

936934

937935
def asarray(data, typecode=None, dtype=None):
938-
"""asarray(data, typecode=None, dtype=None) is equivalent to array(data, dtype=None, copy=0)
936+
"""
937+
asarray(data, typecode=None, dtype=None) is equivalent to array(data, dtype=None, copy=0)
939938
940939
941-
Returns
942-
-------
940+
Returns
941+
-------
943942
944-
data if dtype is None or data is a MaskedArray of the same dtype.
943+
data if dtype is None or data is a MaskedArray of the same dtype.
945944
typecode arg is for backward compatibility.
946945
"""
947946
dtype = _convdtype(dtype, typecode)
@@ -1061,7 +1060,8 @@ def resize(a, new_shape, axes=None, attributes=None, id=None, grid=None):
10611060
-------
10621061
a new array with the specified shape.
10631062
1064-
The original array's total size can be any size."""
1063+
The original array's total size can be any size.
1064+
"""
10651065
ignore, attributes, id, ignore = _extractMetadata(a, axes, attributes, id)
10661066
if axes is not None:
10671067
axesshape = [len(item) for item in axes]
@@ -1099,7 +1099,6 @@ def masked_values(data, value, rtol=1.e-5, atol=1.e-8, copy=1,
10991099
"""
11001100
Parameters
11011101
----------
1102-
11031102
masked_values(data, value, rtol=1.e-5, atol=1.e-8)
11041103
11051104
Create a masked array; mask is None if possible.
@@ -1131,7 +1130,6 @@ def isMaskedVariable(x):
11311130

11321131
def set_default_fill_value(value_type, value):
11331132
"""Set the default fill value for value_type to value.
1134-
11351133
Parameters
11361134
----------
11371135
value_type is a string:
@@ -1164,7 +1162,6 @@ def diagonal(a, offset=0, axis1=0, axis2=1):
11641162
11651163
Returns
11661164
-------
1167-
11681165
the given diagonals defined by the two dimensions of the array.
11691166
"""
11701167
F = getattr(a, "fill_value", 1.e20)

Lib/avariable.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -701,17 +701,15 @@ def getOrder(self, ids=0):
701701
"""
702702
Parameters
703703
----------
704-
705-
id:
706-
0 or 1
704+
id:
705+
0 or 1
707706
708707
Returns
709708
-------
710-
711709
the order string, such as t, z, y, x (time, level, lat, lon).
712710
713711
Note
714-
712+
----
715713
* if ids == 0 (the default) for an axis that is not t,z,x,y
716714
the order string will contain a (-) character in that location.
717715
The result string will be of the same length as the number

Lib/axis.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1255,8 +1255,7 @@ def mapInterval(self, interval, indicator='ccn', cycle=None):
12551255
12561256
Returns
12571257
-------
1258-
1259-
The corresponding index interval (i,j), where i<j, indicating
1258+
The corresponding index interval (i,j), where i<j, indicating
12601259
the half-open index interval [i,j), or None if the intersection is empty.
12611260
12621261
For an axis which is circular (self.topology == 'circular'), [i,j)

Lib/cache.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -326,8 +326,8 @@ def put(self, filekey, path):
326326
327327
Parameters
328328
----------
329-
<filekey>
330-
filekey for cache
329+
filekey:
330+
for cache
331331
"""
332332

333333
filekey = str(filekey)

Lib/database.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ def connect(uri=None, user="", password=""):
5555
Database instance
5656
5757
Example
58-
5958
db = cdms.connect("ldap://dbhost.llnl.gov/database=CDMS,ou=PCMDI,o=LLNL,c=US")
6059
"""
6160
if uri is None:
@@ -312,7 +311,6 @@ def openDataset(self, dsetid, mode='r'):
312311
Dataset instance.
313312
314313
Example
315-
316314
dset = db.openDataset('ncep_reanalysis_mo')
317315
"""
318316
dn = "dataset=%s,%s" % (dsetid, self.path)
@@ -416,7 +414,6 @@ def searchFilter(self, filter=None, tag=None, relbase=None,
416414
Entries can be refined with searchPredicate().
417415
418416
Example
419-
420417
(1) Find all variables named "cli":
421418
422419
result = db.searchFilter(filter="id=cli",tag="variable")
@@ -529,7 +526,6 @@ def searchPredicate(self, predicate, tag=None):
529526
Entries can be refined with searchPredicate().
530527
531528
Example
532-
533529
(1) Find all variables on a 73x96 grid
534530
535531
newresult = result.searchPredicate(lambda obj: obj.getGrid().shape==(73,96),"variable")
@@ -561,11 +557,9 @@ def __init__(self, db):
561557
def getObject(self):
562558
"""
563559
Method
564-
565560
getObject()
566561
567562
Description
568-
569563
Get the CDMS object associated with this entry.
570564
571565
Returns

Lib/dataset.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2138,8 +2138,8 @@ def write(self, var, attributes=None, axes=None, extbounds=None, id=None,
21382138
21392139
Parameters
21402140
----------
2141-
var:
2142-
variable to copy.
2141+
var:
2142+
variable to copy.
21432143
attributes:
21442144
The attribute dictionary for the variable. The default is var.attributes.
21452145
axes:
@@ -2160,6 +2160,7 @@ def write(self, var, attributes=None, axes=None, extbounds=None, id=None,
21602160
The numpy dtype.
21612161
typecode:
21622162
Deprecated, for backward compatibility only
2163+
21632164
Returns
21642165
-------
21652166
File variable
@@ -2316,9 +2317,11 @@ def write_it_yourself(self, obj):
23162317
----------
23172318
obj:
23182319
object containing `writeg`, `writeToFile` or `write` method.
2320+
23192321
Returns
23202322
-------
2321-
Nothig is returned. """
2323+
Nothing is returned.
2324+
"""
23222325
# This method was formerly called writeg and just wrote an
23232326
# AbstractCurveGrid.
23242327
if (hasattr(obj, 'writeg') and callable(getattr(obj, 'writeg'))):

Lib/forecast.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,13 @@ class forecast():
8585
is used to get the forecast file from the forecast time.
8686
8787
Example
88-
-------
8988
90-
Each list item should look like this example:
89+
Each list item should look like this example:
9190
[None, None, None, None, 2006022200000L, 'file2006-02-22-00000.nc']
9291
Normally dataset_list = fm[i][1] where fm is the output of
9392
cdms2.dataset.parseFileMap and fm[i][0] matches the variables of interest.
9493
9594
Note
96-
----
9795
9896
N.B. This is like a CdmsFile. Creating a forecast means opening a file,
9997
so later on you should call forecast.close() to close it.
@@ -139,7 +137,6 @@ def available_forecasts(dataset_file, path="."):
139137
through the specified cdscan-generated dataset xml file.
140138
141139
Note
142-
143140
The forecasts are given in 64-bit integer format, but can be converted
144141
to component times with the function two_times_from_one.
145142
This function may help in choosing the right arguments for initializing
@@ -157,8 +154,6 @@ class forecasts():
157154
Represents a set of forecasts
158155
159156
Example
160-
161-
162157
Creates a set of forecasts. Normally you do it by something like
163158
f = forecasts( 'file.xml', (min_time, max_time) )
164159
or
@@ -256,7 +251,7 @@ def time_interval_to_list(self, tlo, thi, openclosed='co'):
256251
def reduce_inplace(self, min_time, max_time, openclosed='co'):
257252
"""
258253
Example
259-
254+
=======
260255
261256
For a forecasts object f, f( min_time, max_time ) will reduce the
262257
scope of f, to forecasts whose start time t has min_time<=t<max_time.
@@ -366,7 +361,6 @@ def forecast_axis(self, varname, fcss=None):
366361
a tuple (axis,start,length,true_length) where axis is in the forecast direction.
367362
368363
Note
369-
370364
If a list of forecasts be specified, the axis' data will be limited to them."""
371365
if fcss is None:
372366
fcss = self.fcs

Lib/grid.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -752,10 +752,10 @@ def writeScrip(self, cufile, gridTitle=None):
752752
753753
Parameters
754754
----------
755-
cufile:
755+
cufile
756756
is a Cdunif file, NOT a CDMS file.
757757
758-
gridtitle:
758+
gridtitle
759759
is a string identifying the grid.
760760
761761
"""
@@ -768,11 +768,9 @@ def toCurveGrid(self, gridid=None):
768768
769769
Parameters
770770
----------
771-
gridid:
771+
gridid
772772
is the string identifier of the resulting curvilinear grid object.
773773
774-
_: None
775-
776774
"""
777775

778776
from .coord import TransientVirtualAxis, TransientAxis2D

Lib/hgrid.py

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -189,23 +189,20 @@ def fixCutCells(self, nonConvexCells, threshold=270.0):
189189
190190
Parameters
191191
----------
192-
193192
nonConvexCells:
194193
1D numpy array of indices of nonconvex cells, as returned from
195194
checkConvex.
196195
threshold:
197196
positive floating-point value in degrees.
198197
199198
200-
If the difference in longitude values of consecutive boundaries nodes exceeds the
201-
threshold, the cell is considered a cut cell.
202-
203-
On return, the grid boundaries are modified.
199+
If the difference in longitude values of consecutive boundaries nodes
200+
exceeds the threshold, the cell is considered a cut cell. On return,
201+
the grid boundaries are modified.
204202
205203
Returns
206204
-------
207-
208-
value is a 1D array of indices of cells that cannot be repaired.
205+
value is a 1D array of indices of cells that cannot be repaired.
209206
"""
210207

211208
from numpy import take, array
@@ -583,7 +580,7 @@ def writeg(self, file):
583580
file.close()
584581

585582
def write_gridspec(self, filename):
586-
"""writes this grid to a Gridspec-compliant file, or does nothing if there is
583+
"""Writes this grid to a Gridspec-compliant file, or does nothing if there is
587584
already a known file corresponding to this grid. The filename should be a
588585
complete path."""
589586
# This method was never completed because the libCF functionality I had planned to
@@ -600,7 +597,7 @@ def write_gridspec(self, filename):
600597
'The libCF/Gridspec API does not provide for writing CurveGrids<<<')
601598

602599
def init_from_gridspec(self, filename):
603-
"""reads to grid from a Gridspec-compliant file. The filename should be a
600+
"""Reads to grid from a Gridspec-compliant file. The filename should be a
604601
complete path. The contents of the file may overwrite data in the existing
605602
grid object."""
606603
# - This is really a kind of init function. The __init__ function should
@@ -618,7 +615,7 @@ def init_from_gridspec(self, filename):
618615
f.close()
619616

620617
def init_from_gridspec_file(self, f):
621-
"""reads to grid from a Gridspec-compliant file, f. This f should be a
618+
"""Reads to grid from a Gridspec-compliant file, f. This f should be a
622619
CdmsFile object, already open for reading. The contents of the file may
623620
overwrite data in the existing grid object."""
624621
# As for the above init_from_gridspec method, this is really a kind of

Lib/tvariable.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -583,8 +583,8 @@ def clone(self, copyData=1):
583583
-------
584584
585585
a copy of self as a transient variable.
586-
587-
If copyData is 1 (default), make a separate copy of the data."""
586+
If copyData is 1 (default), make a separate copy of the data.
587+
"""
588588
result = createVariable(self, copy=copyData)
589589
return result
590590

0 commit comments

Comments
 (0)