提交 ed94e1c1 编写于 作者: A A. Unique TensorFlower

Internal change

PiperOrigin-RevId: 489221731
上级 0bc69d17
runtime:
distribution_strategy: 'tpu'
mixed_precision_dtype: 'bfloat16'
task:
model:
num_classes: 1001
input_size: [224, 224, 3]
backbone:
type: 'resnet'
resnet:
model_id: 26
losses:
l2_weight_decay: 0.0001
one_hot: true
label_smoothing: 0.1
train_data:
input_path: 'gs://mlcompass-data/imagenet/imagenet-2012-tfrecord/train*'
is_training: true
global_batch_size: 4096
dtype: 'bfloat16'
validation_data:
input_path: 'gs://mlcompass-data/imagenet/imagenet-2012-tfrecord/valid*'
is_training: false
global_batch_size: 4096
dtype: 'bfloat16'
drop_remainder: false
trainer:
train_steps: 28080
validation_steps: 13
validation_interval: 312
steps_per_loop: 312
summary_interval: 312
checkpoint_interval: 312
optimizer_config:
optimizer:
type: 'sgd'
sgd:
momentum: 0.9
learning_rate:
type: 'stepwise'
stepwise:
boundaries: [9360, 18720, 24960]
values: [1.6, 0.16, 0.016, 0.0016]
warmup:
type: 'linear'
linear:
warmup_steps: 1560
......@@ -44,6 +44,12 @@ RESNET_SPECS = {
('residual', 256, 2),
('residual', 512, 2),
],
26: [
('residual', 64, 3),
('residual', 128, 3),
('residual', 256, 3),
('residual', 512, 3),
],
34: [
('residual', 64, 3),
('residual', 128, 4),
......
......@@ -29,6 +29,7 @@ class ResNetTest(parameterized.TestCase, tf.test.TestCase):
@parameterized.parameters(
(128, 10, 1),
(128, 18, 1),
(128, 26, 1),
(128, 34, 1),
(128, 50, 4),
(128, 101, 4),
......@@ -40,6 +41,7 @@ class ResNetTest(parameterized.TestCase, tf.test.TestCase):
resnet_params = {
10: 4915904,
18: 11190464,
26: 17465024,
34: 21306048,
50: 23561152,
101: 42605504,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册