(out, print_source_locations)
| 12455 | return this._op_version; |
| 12456 | } |
| 12457 | print(out, print_source_locations) { |
| 12458 | out.write('graph('); |
| 12459 | torch._C.const_value_list_with_types(out, this.inputs(), ',\n '); |
| 12460 | out.write('):\n'); |
| 12461 | const groups = []; |
| 12462 | for (const node of this.nodes()) { |
| 12463 | node.print(out, 1, groups, print_source_locations); |
| 12464 | } |
| 12465 | out.write(' return ('); |
| 12466 | torch._C.printValueRefs(out, this.outputs()); |
| 12467 | out.write(')\n'); |
| 12468 | for (let i = 0; i < groups.length; i++) { |
| 12469 | const fg = groups[i]; |
| 12470 | out.write('with '); |
| 12471 | out.write(fg.kind()); |
| 12472 | out.write(`_${i} = `); |
| 12473 | out.write(fg.g('Subgraph')); |
| 12474 | } |
| 12475 | return out; |
| 12476 | } |
| 12477 | toString() { |
| 12478 | const out = new io.StringIO(); |
| 12479 | this.print(out, true); |
no test coverage detected