Skip to content

Commit 28a746f

Browse files
committed
allow potsdam example to be run w/o downloading files
1 parent 775e295 commit 28a746f

File tree

1 file changed

+6
-2
lines changed
  • rastervision_pytorch_backend/rastervision/pytorch_backend/examples/semantic_segmentation

1 file changed

+6
-2
lines changed

rastervision_pytorch_backend/rastervision/pytorch_backend/examples/semantic_segmentation/isprs_potsdam.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ def get_config(runner,
4444
external_model: bool = True,
4545
augment: bool = False,
4646
nochip: bool = True,
47+
allow_streaming: bool = False,
4748
num_epochs: int = 10,
4849
batch_sz: int = 8,
4950
test: bool = False) -> SemanticSegmentationConfig:
@@ -142,7 +143,9 @@ def make_scene(id) -> SceneConfig:
142143
label_uri = label_crop_uri
143144

144145
raster_source = RasterioSourceConfig(
145-
uris=[raster_uri], channel_order=channel_order)
146+
uris=[raster_uri],
147+
channel_order=channel_order,
148+
allow_streaming=allow_streaming)
146149

147150
# Using with_rgb_class_map because label TIFFs have classes encoded as
148151
# RGB colors.
@@ -151,7 +154,8 @@ def make_scene(id) -> SceneConfig:
151154
uris=[label_uri],
152155
transformers=[
153156
RGBClassTransformerConfig(class_config=class_config)
154-
]))
157+
],
158+
allow_streaming=allow_streaming))
155159

156160
# URI will be injected by scene config.
157161
# Using rgb=True because we want prediction TIFFs to be in

0 commit comments

Comments
 (0)