<div dir="ltr"><div><div>Great that you found it!<br><br>Thanks a lot, Soeren! I'll keep an eye on it to update as soon as it is available in trunk :)<br><br></div>cheers,<br></div>Vero<br><div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">2017-04-27 21:03 GMT+02:00 Sören Gebbert <span dir="ltr"><<a href="mailto:soerengebbert@googlemail.com" target="_blank">soerengebbert@googlemail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Vero,<br>
this seems to be a bug introduced 14 month ago by someone who<br>
implemented the time suffix. The indicator maps should have added<br>
"_indicator" to their name to distinguish between occurrence and<br>
indicator maps. I will fix this in trunk.<br>
<br>
Ciao<br>
<span class="HOEnZb"><font color="#888888">Sören<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
2017-04-27 20:27 GMT+02:00 Veronica Andreo <<a href="mailto:veroandreo@gmail.com">veroandreo@gmail.com</a>>:<br>
> An update:<br>
><br>
> I investigated outputs a bit more... The output maps that are registered in<br>
> the occurrence strds contain the range of values that is described for<br>
> indicator strds (from 1 to 3), and are in fact generated by something like<br>
> this: if(isnull(eip1_2005_09_28), if(isnull(eip1_2005_09_29), null(), 1),<br>
> if(isnull(eip1_2005_09_29), null(), 2)) <<-- that seems to be the indicator.<br>
> The occurrence maps that are supposed to store the time in days from the<br>
> beginning of the cycle, are not there (or they are overwritten at some<br>
> point, dunno).<br>
><br>
> In summary, the indicator maps are generated and registered in the<br>
> occurrence strds. The occurrence maps are not created (or they are<br>
> overwritten, dunno) and indicator strds is empty.<br>
><br>
> My question would however, if the output are two strds, wouldn't we need to<br>
> provide two basenames??<br>
><br>
> best,<br>
> Vero<br>
><br>
> 2017-04-27 19:22 GMT+02:00 Veronica Andreo <<a href="mailto:veroandreo@gmail.com">veroandreo@gmail.com</a>>:<br>
>><br>
>> Hello list,<br>
>><br>
>> I have accumulated a daily time series of temperatures with BEDD method by<br>
>> means of t.rast.accumulate, and now, I need to identify where do the cycles<br>
>> occur and how much do they last. However, when I run t.rast.accdetect, all<br>
>> goes fine until I get this error:<br>
>><br>
>> Traceback (most recent call last):<br>
>>   File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/scripts/t.rast.<wbr>accdetect",<br>
>> line 592, in <module><br>
>> ERROR: Unable to execute transaction:<br>
>> INSERT INTO raster_base ( name ,creator ,mapset     ,creation_timemain()<br>
>><br>
>> ,temporal_type ,id   File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/scripts/t.rast.<wbr>accdetect",<br>
>> line 437, in main<br>
>> ) VALUES ('eip2_2003_08_01' ,'veroandreo' ,'lst'<br>
>> ,'2017-04-27 18:55:42.175407' ,'absolute' ,'eip2_2003_08_01@lst') ;<br>
>> INSERT INTO raster_absolute_time ( start_time ,id ,end_time ) VALUES<br>
>> ('2003-08-01 00:00:00' ,'eip2_2003_08_01@lst' ,'2003-08-02 00:00:00') ;<br>
>> INSERT     register_null, empty_maps, dbif)<br>
>> INTO  File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/scripts/t.rast.<wbr>accdetect",<br>
>> line 479, in create_strds_register_maps<br>
>>  raster_spatial_extent ( north ,bottom ,west ,top ,proj ,east<br>
>> ,id ,south ) VALUES (2428000.000000 ,0.000000 ,4821000.000000 ,0.000000<br>
>> ,'XY' ,6309000.000000 ,'eip2_2003_08_01@lst' ,1312000.000000) ;<br>
>> INSERT INTO raster_metadata     (map.insert(dbif)<br>
>>  max  File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/etc/python/grass/<wbr>temporal/abstract_map_dataset.<wbr>py",<br>
>> line 283, in insert<br>
>>  ,rows ,min ,datatype ,number_of_cells<br>
>> ,cols ,ewres ,nsres ,id ) VALUES (3.000000 ,1488 ,1.000000 ,'CELL'<br>
>> ,1660608<br>
>> ,1116     return AbstractDataset.insert(self, dbif=dbif, execute=execute)<br>
>> ,1000.000000   File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/etc/python/grass/<wbr>temporal/abstract_dataset.py",<br>
>> line 403, in insert<br>
>> ,1000.000000 ,'eip2_2003_08_01@lst') ;<br>
>> INSERT INTO raster_stds_register ( id ,registered_stds ) VALUES<br>
>> ('eip2_2003_08_01@lst' ,NULL) ;<br>
>>     dbif.execute_transaction(<wbr>statement)<br>
>>   File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/etc/python/grass/<wbr>temporal/core.py",<br>
>> line 1020, in execute_transaction<br>
>>     return self.connections[mapset].<wbr>execute_transaction(statement)<br>
>>   File<br>
>> "/home/veroandreo/software/<wbr>grass7_trunk/dist.x86_64-pc-<wbr>linux-gnu/etc/python/grass/<wbr>temporal/core.py",<br>
>> line 1314, in execute_transaction<br>
>>     self.cursor.executescript(<wbr>statement)<br>
>> sqlite3.IntegrityError: UNIQUE constraint failed: <a href="http://raster_base.id" rel="noreferrer" target="_blank">raster_base.id</a><br>
>><br>
>> I have no clue of what is wrong... Here are the commands I'm using (I'm<br>
>> following the example in t.rast.accumulate manual page)<br>
>><br>
>> # accumulation<br>
>> t.rast.accumulate -n input=reconstructed_lst output=daily_bedd \<br>
>>  start="2003-04-01" stop="2005-09-30" \<br>
>>  cycle="6 months" offset="6 months" granularity="1 day" \<br>
>>  basename=daily_bedd suffix=gran method=bedd limits=14,32 \<br>
>>  scale=0.02 shift=-273.15 --o<br>
>><br>
>> # detect cycle 1:<br>
>> t.rast.accdetect input=daily_bedd \<br>
>>   occurrence=occurrence_eip1 start="2003-04-01" stop="2005-09-30" \<br>
>>   cycle="6 months" offset="6 months" range=109,218 \<br>
>>   basename=eip1 indicator=indicator_eip1<br>
>><br>
>> The maps are created (basename=eip1) and they contain data, the occurrence<br>
>> strds is also created and contains the eip1 maps, but the indicator strds is<br>
>> empty. And this one (the indicator strds) is the one needed to identify<br>
>> where do the target cycles occur.<br>
>><br>
>> I would really appreciate any help and advice... please :)<br>
>><br>
>> Thanks much<br>
>> Vero<br>
><br>
><br>
><br>
</div></div><div class="HOEnZb"><div class="h5">> ______________________________<wbr>_________________<br>
> grass-user mailing list<br>
> <a href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a><br>
> <a href="https://lists.osgeo.org/mailman/listinfo/grass-user" rel="noreferrer" target="_blank">https://lists.osgeo.org/<wbr>mailman/listinfo/grass-user</a><br>
</div></div></blockquote></div><br></div>