Skip to content

Commit

Permalink
fix flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
dnadeau4 committed Feb 7, 2019
1 parent 6dc35a6 commit a129daf
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
20 changes: 10 additions & 10 deletions Lib/cdscan.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ def combineKeys(mydict, typedict, timeIsLinear=0,
if name0 is None:
name0 = name
values, units, dummy = typedict[(path, name)]
if firstunits is "":
if firstunits == "":
firstunits = units
if prevend is not None and prevend >= i0:
if prevend >= i1:
Expand Down Expand Up @@ -620,15 +620,15 @@ def initialize_filemap(filemap, timedict, levdict, timeid, extendDset, splitOnTi
referenceTime, timeIsLinear, referenceDelta, splitOnLevel,
dirlen, overrideCalendar):
# This function was formerly part of the body of "main".
# Initialize filemap : varid => (tc0, tc1, lc0, lc1, path, timeid, levid)
# where tc0 is the first time index relative to the reference time, tc1 the last,
# lc0 is the first level, lc1 the last, path is the filename, timeid is the id
# of the time dimension of the variable, levid is the id of the level dimension
#
# timedict : (path, timeid) => (timearray, timeunits, calendar)
#
# levdict : (path, levelid) => (levelarray, levelunits, None)
#
# Initialize filemap : varid => (tc0, tc1, lc0, lc1, path, timeid, levid)
# where tc0 is the first time index relative to the reference time, tc1 the last,
# lc0 is the first level, lc1 the last, path is the filename, timeid is the id
# of the time dimension of the variable, levid is the id of the level dimension
#
# timedict : (path, timeid) => (timearray, timeunits, calendar)
#
# levdict : (path, levelid) => (levelarray, levelunits, None)
#
initfilemap = cdms2.dataset.parseFileMap(extendDset.cdms_filemap)
dsetdirec = extendDset.directory
for namelist, slicelist in initfilemap:
Expand Down
2 changes: 1 addition & 1 deletion Lib/tvariable.py
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ def __new__(cls, data, typecode=None, copy=0, savespace=0,
if dtype is None and data is not None:
dtype = numpy.array(data).dtype

if any(x is 'N/A' for x in str(fill_value)):
if any(x == 'N/A' for x in str(fill_value)):
fill_value = None

if fill_value is not None:
Expand Down

0 comments on commit a129daf

Please sign in to comment.