Skip to content

Remove the argument include_COG from add_layer #17

Description

@evandjpl

Without that argument, the function does nothing.

def add_layer(
self,
variable_name: str,
image: Raster,
cmap: Union[Colormap, str] = None,
include_COG: bool = True,
include_geojpeg: bool = True) -> str:

if include_COG:
image.to_COG(
filename=filename,
compress=self.compression,
preview_filename=preview_filename,
preview_quality=self.layer_preview_quality,
cmap=cmap
)

Without include_COG being true, no output layers are generated. This appears to have been intended as a switch to allow you to either generate COG, geoJPG, or both, at one point in time. Since then, the functionality to generate only a geoJPG was removed, and as a result the input flag should be removed as well.

Link to the original change for those with access to the historical repositories:
https://github.jpl.nasa.gov/gregory-repositories/ECOSTRESS-ROSES/commit/7cc4340331ec1f7871e8c4b05dff0afb477cd438#diff-65cf83642642d79b15a00c126c8af28da66b0ebdc5277aa0e7b4ddb02ca03b26

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions