pd_op.yaml 7.4 KB
Newer Older
1
- name: feed
K
kangguangli 已提交
2
  inputs: []
3
  attrs:
K
kangguangli 已提交
4
  - {typename: str, name: name}
H
hong 已提交
5
  - {typename: int, name: col}
6 7 8 9 10 11
  outputs:
  - {typename: Tensor, name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  inplace: null
  backward: null
12

13 14 15 16 17 18 19 20
- name: fetch
  inputs:
  - typename: Tensor
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
K
kangguangli 已提交
21
  - {typename: str, name: name}
H
hong 已提交
22
  - {typename: int, name: col}
H
hong 已提交
23
  outputs:
24
    - {typename: Tensor, name: out, optional: false, intermediate: false}
25 26
  no_need_buffer: null
  data_transform: null
H
hong 已提交
27 28 29 30 31 32 33 34 35 36 37
  infer_meta:
    func: UnchangedInferMeta
    param: [x]
  kernel:
    func: [fetch]
    param: [x]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
38 39
  inplace: null
  backward: null
40

H
hong 已提交
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67
- name: save_combine
  inputs:
  - typename: Tensor[]
    name: X
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
  - {typename: str, name: file_path}
  - {typename: bool, name: overwrite}
  - {typename: bool, name: save_as_fp16}
  - {typename: bool, name: save_to_memory}
  outputs:
    - {typename: Tensor, name: out, optional: true, intermediate: false}
  no_need_buffer: null
  data_transform: null
  kernel:
    func: [save_combine_tensor]
    param: [X, file_path, overwrite, save_as_fp16, save_to_memory]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
  inplace: null
  backward: null

H
hong 已提交
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88
- name: load_combine
  inputs: []
  attrs:
  - {typename: str, name: file_path}
  - {typename: bool, name: load_as_fp16}
  - {typename: bool, name: model_from_memory}
  outputs:
    - {typename: 'Tensor[]', name: out, optional: true, intermediate: false}
  no_need_buffer: null
  data_transform: null
  kernel:
    func: [load_combine]
    param: [file_path, load_as_fp16, model_from_memory]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
  inplace: null
  backward: null

89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141
- name: share_buffer_
  inputs:
  - typename: Tensor[]
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
  - {typename: 'bool[]', name: share_dims_and_dtype, default_value: '{}'}
  outputs:
  - {typename: 'Tensor[]', name: out, size: x.size(), optional: false, intermediate: false}
  - {typename: 'Tensor[]', name: xout, size: x.size(), optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  inplace: null
  backward: null

- name: assert
  inputs:
  - typename: Tensor
    name: cond
    optional: false
    no_need_buffer: false
    data_transform: {}
  - typename: Tensor[]
    name: data
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
  - {typename: 'int64_t', name: summarize, default_value: '-1'}
  outputs: []
  no_need_buffer: null
  data_transform: null
  inplace: null
  backward: null

- name: print
  inputs:
  - typename: Tensor
    name: in
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
  - {typename: 'int', name: first_n}
  - {typename: 'str', name: message}
  - {typename: 'int', name: summarize}
  - {typename: 'bool', name: print_tensor_name, default_value: 'true'}
  - {typename: 'bool', name: print_tensor_type, default_value: 'true'}
  - {typename: 'bool', name: print_tensor_shape, default_value: 'true'}
  - {typename: 'bool', name: print_tensor_layout, default_value: 'true'}
  - {typename: 'bool', name: print_tensor_lod, default_value: 'true'}
H
hong 已提交
142
  - {typename: 'str', name: print_phase, default_value: '"BOTH"'}
143 144 145 146 147 148 149
  - {typename: 'bool', name: is_forward, default_value: 'true'}
  outputs:
    - typename: Tensor
      name: out
      optional: false
      no_need_buffer: false
      data_transform: {}
H
hong 已提交
150 151 152 153 154 155 156 157 158 159 160
  infer_meta:
    func: UnchangedInferMeta
    param: [in]
  kernel:
    func: [print_kernel]
    param: [in, first_n, message, summarize, print_tensor_name, print_tensor_type, print_tensor_shape, print_tensor_layout, print_tensor_lod, print_phase, is_forward ]
    backend: null
    layout: null
    data_type: null
    dispatch: {print: null}
    force_backend: null
161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177
  no_need_buffer: null
  data_transform: null
  inplace: null
  backward: null

- name: add_n_
  inputs:
  - typename: Tensor[]
    name: inputs
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs: []
  outputs:
  - {typename: Tensor, name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213
  infer_meta:
    func: AddNInferMeta
    param: [inputs]
  kernel:
    func: [add_n]
    param: [inputs]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
  backward: add_n_grad

- name: add_n_with_kernel
  inputs:
  - typename: Tensor[]
    name: inputs
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs: []
  outputs:
  - {typename: Tensor, name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  infer_meta:
    func: AddNInferMeta
    param: [inputs]
  kernel:
    func: [add_n]
    param: [inputs]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247
  backward: add_n_grad

- name: write_to_array
  inputs:
  - typename: Tensor
    name: i
    optional: false
    no_need_buffer: false
    data_transform: {}
  - typename: Tensor
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs: []
  outputs:
  - {typename: 'Tensor[]', name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  backward: write_to_array_grad

- name: lod_array_length
  inputs:
  - typename: Tensor[]
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs: []
  outputs:
  - {typename: 'Tensor', name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null

248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272
- name: embedding_grad_sparse
  inputs:
  - typename: Tensor
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  - typename: Tensor
    name: weight
    optional: false
    no_need_buffer: false
    data_transform: {}
  - typename: Tensor
    name: out_grad
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs:
  - {typename: int64_t, name: padding_idx, default_value: '-1'}
  - {typename: bool, name: sparse, default_value: 'false'}
  outputs:
  - {typename: SelectedRows, name: weight_grad, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  infer_meta:
H
hong 已提交
273
    func: EmbeddingGradSparseInferMeta
274 275
    param: [weight]
  kernel:
H
hong 已提交
276
    func: [embedding_sparse_grad]
277 278 279 280 281 282 283
    param: [x, weight, out_grad, padding_idx, sparse]
    backend: null
    layout: null
    data_type:
      ordered: false
      candidates: [weight]
      to_complex_flag: [false]
H
hong 已提交
284
    dispatch: {embedding_sparse_grad: null}
285 286 287 288
    force_backend: null
  inplace: null
  view: null
  backward: null
289 290


H
hong 已提交
291
- name: shadow_feed
292 293 294 295 296 297 298 299 300 301 302 303 304 305 306
  inputs:
  - typename: Tensor
    name: x
    optional: false
    no_need_buffer: false
    data_transform: {}
  attrs: []
  outputs:
    - {typename: Tensor, name: out, optional: false, intermediate: false}
  no_need_buffer: null
  data_transform: null
  infer_meta:
    func: UnchangedInferMeta
    param: [x]
  kernel:
H
hong 已提交
307
    func: [shadow_feed]
308 309 310 311 312 313 314 315
    param: [x]
    backend: null
    layout: null
    data_type: null
    dispatch: {fetch: null}
    force_backend: null
  inplace: null
  backward: null