"...libs/git@developer.sourcefind.cn:wangsen/mineru.git" did not exist on "f7120c82015eaece8302a5c51f9c124d7fe4cd7f"
Commit c33d6bae authored by Abdullah Rashwan's avatar Abdullah Rashwan Committed by A. Unique TensorFlower
Browse files

Internal change

PiperOrigin-RevId: 350850704
parent 5d5441a1
...@@ -407,7 +407,8 @@ def seg_deeplabv3plus_cityscapes() -> cfg.ExperimentConfig: ...@@ -407,7 +407,8 @@ def seg_deeplabv3plus_cityscapes() -> cfg.ExperimentConfig:
decoder=decoders.Decoder( decoder=decoders.Decoder(
type='aspp', type='aspp',
aspp=decoders.ASPP( aspp=decoders.ASPP(
level=level, dilation_rates=aspp_dilation_rates)), level=level, dilation_rates=aspp_dilation_rates,
pool_kernel_size=[512, 1024])),
head=SegmentationHead( head=SegmentationHead(
level=level, level=level,
num_convs=2, num_convs=2,
...@@ -423,7 +424,7 @@ def seg_deeplabv3plus_cityscapes() -> cfg.ExperimentConfig: ...@@ -423,7 +424,7 @@ def seg_deeplabv3plus_cityscapes() -> cfg.ExperimentConfig:
train_data=DataConfig( train_data=DataConfig(
input_path=os.path.join(CITYSCAPES_INPUT_PATH_BASE, input_path=os.path.join(CITYSCAPES_INPUT_PATH_BASE,
'train_fine**'), 'train_fine**'),
output_size=[1024, 2048], output_size=[512, 1024],
train_on_crops=True, train_on_crops=True,
is_training=True, is_training=True,
global_batch_size=train_batch_size, global_batch_size=train_batch_size,
......
...@@ -111,10 +111,6 @@ class Parser(parser.Parser): ...@@ -111,10 +111,6 @@ class Parser(parser.Parser):
image, label = self._prepare_image_and_label(data) image, label = self._prepare_image_and_label(data)
if self._train_on_crops: if self._train_on_crops:
if data['image/height'] < self._output_size[0] or data[
'image/width'] < self._output_size[1]:
raise ValueError(
'Image size has to be larger than crop size (output_size)')
label = tf.reshape(label, [data['image/height'], data['image/width'], 1]) label = tf.reshape(label, [data['image/height'], data['image/width'], 1])
image_mask = tf.concat([image, label], axis=2) image_mask = tf.concat([image, label], axis=2)
image_mask_crop = tf.image.random_crop(image_mask, image_mask_crop = tf.image.random_crop(image_mask,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment