Skip to content

Commit

Permalink
Fixed a bug where some observations would have been ignored; this onl…
Browse files Browse the repository at this point in the history
…y existed in the v1.0 version of rsdtlib, not in the original ERCNN-DRS variant
  • Loading branch information
gzitzlsb-it4i committed Mar 27, 2023
1 parent aa44618 commit 774d3d8
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions lib/rsdtlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -928,11 +928,11 @@ def _bytes_feature(value):
self.bands_sar)

idx = 0
new_sar_asc = False
new_sar_dsc = False
new_opt = False
print("List of observations to process:")
for timestep in list_time_stamps:
new_sar_asc = False
new_sar_dsc = False
new_opt = False
for item in timestep[1]: # Expected is one item due to no collisions
if item[0] == self._RS_Type.SAR_ASC:
new_patch = EOPatch.load(item[1])
Expand Down Expand Up @@ -995,6 +995,7 @@ def _bytes_feature(value):
self.tile_size_y,
self.tile_size_x,
self.bands_sar)
new_sar_asc = False

if new_sar_dsc:
prev_frame_SAR_descending_t = self._tile_stream(
Expand All @@ -1004,6 +1005,7 @@ def _bytes_feature(value):
self.tile_size_y,
self.tile_size_x,
self.bands_sar)
new_sar_dsc = False

if new_opt:
prev_frame_OPT_t = self._tile_stream(
Expand All @@ -1013,6 +1015,7 @@ def _bytes_feature(value):
self.tile_size_y,
self.tile_size_x,
self.bands_opt)
new_opt = False

# Write all tiles
tf_ts = timestep[0].replace(tzinfo=timezone.utc).timestamp()
Expand Down

0 comments on commit 774d3d8

Please sign in to comment.