提交 a0ac1339 编写于 作者: T typhoonzero

update job

上级 311d159e
...@@ -21,6 +21,8 @@ spec: ...@@ -21,6 +21,8 @@ spec:
env: env:
- name: PADDLE_JOB_NAME - name: PADDLE_JOB_NAME
value: vgg16job value: vgg16job
- name: OMP_NUM_THREADS
value: "1"
- name: TRAINERS - name: TRAINERS
value: "20" value: "20"
- name: PSERVERS - name: PSERVERS
...@@ -36,7 +38,7 @@ spec: ...@@ -36,7 +38,7 @@ spec:
- name: PADDLE_INIT_NICS - name: PADDLE_INIT_NICS
value: "xgbe0" value: "xgbe0"
- name: PADDLE_INIT_TRAINER_COUNT - name: PADDLE_INIT_TRAINER_COUNT
value: "1" value: "2"
- name: PADDLE_INIT_PORTS_NUM - name: PADDLE_INIT_PORTS_NUM
value: "1" value: "1"
- name: PADDLE_INIT_PORTS_NUM_FOR_SPARSE - name: PADDLE_INIT_PORTS_NUM_FOR_SPARSE
...@@ -44,7 +46,7 @@ spec: ...@@ -44,7 +46,7 @@ spec:
- name: PADDLE_INIT_NUM_GRADIENT_SERVERS - name: PADDLE_INIT_NUM_GRADIENT_SERVERS
value: "20" value: "20"
- name: PADDLE_INIT_NUM_PASSES - name: PADDLE_INIT_NUM_PASSES
value: "1" value: "2"
- name: PADDLE_INIT_USE_GPU - name: PADDLE_INIT_USE_GPU
value: "0" value: "0"
- name: LD_LIBRARY_PATH - name: LD_LIBRARY_PATH
......
...@@ -74,14 +74,14 @@ def vgg19(input, class_dim): ...@@ -74,14 +74,14 @@ def vgg19(input, class_dim):
def main(): def main():
paddle.init(use_gpu=False, trainer_count=1) paddle.init(use_gpu=False)
image = paddle.layer.data( image = paddle.layer.data(
name="image", type=paddle.data_type.dense_vector(DATA_DIM)) name="image", type=paddle.data_type.dense_vector(DATA_DIM))
lbl = paddle.layer.data( lbl = paddle.layer.data(
name="label", type=paddle.data_type.integer_value(CLASS_DIM)) name="label", type=paddle.data_type.integer_value(CLASS_DIM))
extra_layers = None extra_layers = None
learning_rate = 0.01 learning_rate = 1e-3
out = vgg16(image, class_dim=CLASS_DIM) out = vgg16(image, class_dim=CLASS_DIM)
cost = paddle.layer.classification_cost(input=out, label=lbl) cost = paddle.layer.classification_cost(input=out, label=lbl)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册