[GRASS-SVN] r73415 - grass-addons/grass7/imagery/i.modis/i.modis.import
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Sep 26 12:16:42 PDT 2018
Author: lucadelu
Date: 2018-09-26 12:16:42 -0700 (Wed, 26 Sep 2018)
New Revision: 73415
Modified:
grass-addons/grass7/imagery/i.modis/i.modis.import/i.modis.import.py
Log:
i.modis.import: improve t.register output, see #3654
Modified: grass-addons/grass7/imagery/i.modis/i.modis.import/i.modis.import.py
===================================================================
--- grass-addons/grass7/imagery/i.modis/i.modis.import/i.modis.import.py 2018-09-26 16:58:03 UTC (rev 73414)
+++ grass-addons/grass7/imagery/i.modis/i.modis.import/i.modis.import.py 2018-09-26 19:16:42 UTC (rev 73415)
@@ -302,6 +302,8 @@
fdata = data + timedelta(days)
if days == 31:
fdata = datetime(fdata.year, fdata.month, 1)
+ if days != 1 and data.year != fdata.year:
+ fdata = datetime(fdata.year, fdata.month, 1)
listfile.write("{name}|{sd}|{fd}\n".format(name=basename,
sd=data.strftime("%Y-%m-%d"),
fd=fdata.strftime("%Y-%m-%d")))
More information about the grass-commit
mailing list