Reconstruct Regression Image from Patches #1997
-
Hi, I wanted to know if you all have a built-in method/module for reconstructing an image from patches using real values? I'm thinking in terms of an autoencoder. # initialize dataset
ds: RegressionDataset = ...
# make predictions
predictions: Float[Array, "B C H W"] = ...
# reconstruct from predictions
ds_labels: Dataset = RegressionLabels.from_predictions(ds.windows, predictions) I've seen this for the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Unfortunately, we currently do not have a built-in If we were to implement it, I imagine it would look pretty similar to the I think you might be able to get away with the following. Let me know if it works. ds_labels: Dataset = SemanticSegmentationSmoothLabels.from_predictions(ds.windows, predictions)
ds_labels.save(
uri='/path/to/pred_dir/',
crs_transformer=ds.scene.raster_source.crs_transformer,
class_config=class_config,
smooth_output=True,
discrete_output=False,
) |
Beta Was this translation helpful? Give feedback.
Unfortunately, we currently do not have a built-in
Labels
orLabelStore
subclass for regression. Support for regression is limited to theRegression*Dataset
classes, theRegressionLearner
, and theRegressionVisualizer
.If we were to implement it, I imagine it would look pretty similar to the
SemanticSegmentationSmoothLabels
class. In fact, it might even be possible to use it directly for regression without any changes.I think you might be able to get away with the following. Let me know if it works.