| 12412 | return n.output(); |
| 12413 | } |
| 12414 | insertFunctionCall(callee, matched) { |
| 12415 | const func_name = callee.name(); |
| 12416 | const fn_constant = this.insertNode(this.create('prim::Constant')).s_('name', func_name).output().setType(torch._C.FunctionType.create(callee)); |
| 12417 | const inputs = [fn_constant, ...matched.inputs]; |
| 12418 | const result = this.insertNode(this.create('prim::CallFunction', inputs)).output().setType(matched.return_types[0]); |
| 12419 | return result; |
| 12420 | } |
| 12421 | insertPoint() { |
| 12422 | return this._insert_before; |
| 12423 | } |