[GRASS-user] t.rast.accdetect failing

Sören Gebbert soerengebbert at googlemail.com
Mon Jul 10 00:56:36 PDT 2017

This seems to be a bug in the name creation of the output raster maps. Can
you please try grass 7.3? Mybe it was already fixed there.

Best regards

Am 10.07.2017 9:53 AM schrieb "Micha Silver" <tsvibar at gmail.com>:


I'm trying to do pattern detection of an STRDS (hourly precipitation from
radar images) with a cycle of 3 hrs. The last step, t.rast.accdetect errors
as follows (after finishing to create the pattern rasters):

Traceback (most recent call last):
  File "/usr/lib/grass72/scripts/t.rast.accdetect", line 592, in <module>
ERROR: Unable to     main()
execute transaction:  File "/usr/lib/grass72/scripts/t.rast.accdetect",
line 437, in main

INSERT INTO raster_base ( name ,creator ,mapset ,creation_time
,temporal_type ,id ) VALUES ('pat_2016_07_12_10' ,'micha' ,'micha'
,'2017-07-09 23:51:24.106063' ,'absolute' ,'pat_2016_07_12_10 at micha') ;
INSERT INTO raster_absolute_time ( start_time     ,idregister_null,
empty_maps, dbif)
 ,end_time )  File "/usr/lib/grass72/scripts/t.rast.accdetect", line 479,
in create_strds_register_maps
('2016-07-12 10:00:00' ,'pat_2016_07_12_10 at micha' ,'2016-07-12 11:00:00') ;
INSERT INTO raster_spatial_extent ( north ,bottom ,west ,top ,proj ,east
,id ,south ) VALUES (-3758645.000000 ,0.000000 ,-523462.000000 ,0.000000
,'XY' ,376538.000000 ,'pat_2016_07_12_10 at micha' ,-4658645.000000) ;
INSERT INTO raster_metadata ( max ,rows     map.insert(dbif)
,min   File "/usr/lib/grass72/etc/python/grass/temporal/abstract_map_dataset.py",
line 275, in insert
,datatype ,number_of_cells
,cols ,ewres ,nsres ,id ) VALUES (2.000000 ,900 ,1.000000 ,'CELL' ,810000
,900     return AbstractDataset.insert(self, dbif=dbif, execute=execute)
,1000.000000 ,1000.000000  File "/usr/lib/grass72/etc/python/g
rass/temporal/abstract_dataset.py", line 405, in insert
 ,'pat_2016_07_12_10 at micha') ;
INSERT INTO raster_stds_register ( id ,registered_stds ) VALUES
('pat_2016_07_12_10 at micha' ,NULL) ;
  File "/usr/lib/grass72/etc/python/grass/temporal/core.py", line 1021, in
    return self.connections[mapset].execute_transaction(statement)
  File "/usr/lib/grass72/etc/python/grass/temporal/core.py", line 1315, in
sqlite3.IntegrityError: UNIQUE constraint failed: raster_base.id

If I understand correctly, the 'id' (Primary Key) in raster_base is created
from the raster name and mapset. So why am I getting this "UNIQUE
constraint failed" error? Any tips?

Thanks, Micha

Micha Silver
Ben Gurion Univ.
Sde Boker, Remote Sensing Lab

grass-user mailing list
grass-user at lists.osgeo.org
-------------- nächster Teil --------------
Ein Dateianhang mit HTML-Daten wurde abgetrennt...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20170710/dcfa3799/attachment.html>

More information about the grass-user mailing list