-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tiler module #41
Tiler module #41
Conversation
… the larger scene-level datacube
for more information, see https://pre-commit.ci
FYI I am using the following snippet to plot the merged data for visual cross-checks: def plot(merged):
"""
Plot a tile in RGB and vh, and DEM
"""
import numpy
from matplotlib import pyplot as plt
# data = merged.coarsen(x=100, y=100, boundary="trim").mean()
data = merged
fig, axs = plt.subplots(3)
rgb = (
numpy.array(
[
data.get("B04"),
data.get("B03"),
data.get("B02"),
]
).clip(0, 3000)
/ 3000
)
axs[0].imshow(rgb.transpose(1, 2, 0))
axs[1].imshow(numpy.log(data.get("vh")))
axs[2].imshow(data.get("DEM"))
plt.show() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haven't had time to test this, was focused on fixing the cube. But looks good from a high level.
…/- 3 day surrounding interval
Added a catch for sampled S2 reference dates which don't have S1 scenes within the +/- 3 day surrounding interval. This should prevent any failures due to unavailable matchup as it just triggers a new sampling for S2. |
Going to merge this to keep things moving. Will address the tile saving method in a follow-up PR. |
for more information, see https://pre-commit.ci
Tiling module that generates 256x256 tiled
xarray
datasets from the larger scene-level datacube generated indatacube.py
.To do:
datacube
module followed by thetile
modulexarray
datasets