satellit_sam.core.image
satellit_sam.core.image
Auto-generated from
satellit_sam/src/satellit_sam/core/image.pybysatellit_sam/scripts/generate_api_docs.py.
Image data model and I/O helpers used across SAM workflows.
Functions
No public module-level functions.
Classes
Image
In-memory image wrapper used throughout the CLI workflows.
Attributes
channels: intdata: np.ndarraysize: tuple[int, int]
Methods
copy
def copy(self) -> "Image":
Return a copy of the image.
save
def save(self, path: str) -> None:
Save the image to disk.
Arguments
path: Destination image path.
load
def load(path: str) -> "Image":
Load an image from disk.
Arguments
path: Source path for the image file.
Returns
Loaded image object.
Exceptions
FileNotFoundError: If OpenCV cannot read the file.
crop
def crop(self, start_x: int, start_y: int, end_x: int, end_y: int) -> "Image":
Create a cropped view from pixel bounds.
Arguments
start_x: Inclusive start x-coordinate. start_y: Inclusive start y-coordinate. end_x: Exclusive end x-coordinate. end_y: Exclusive end y-coordinate.
Returns
Cropped image.