Skip to content

Commit

Permalink
Adding getter for raw_event device.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriele Meoni committed Mar 1, 2024
1 parent 831000b commit 83441ec
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions pyraws/raw/raw_event.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,29 +220,40 @@ def get_bands_list(self):
return self.__bands_names

def get_bounding_box_dict(self):
"""Get bounding box dictionaries.
"""Bounding box dictionaries getter.
Returns:
dict: Returns {useful granules : bounding box dictionary}
"""
return self.__useful_granule_bounding_box_dict

def get_event_class(self):
"""Get event class.
"""Event class getter.
Returns:
dict: Returns {useful granules : bounding box dictionary}
"""
return self.__event_class

def get_granule(self, granule_idx):
"""It returns the granule addressed by granule_idx.
"""Returns the granule addressed by granule_idx.
Args:
granule_idx (int): granule index.
Returns:
raw_granule: raw granule matching the corresponding index.
"""
return self.__granules_collection[granule_idx]

def get_device(self):
"""Returns the used device.
Returns:
torch.device: used torch device.
"""
return self.__device


def get_stackable_granules(self):
"""Returns list of stackable granules couples indices and stacking positions.
Expand Down

0 comments on commit 83441ec

Please sign in to comment.