4876813c7e094c70c64adeae4a32e7983c7842e1,python/tvm/relay/frontend/coreml.py,,from_coreml,#Any#Any#,496

Before Change


        layerop = getattr(l, layertype)
        assert len(l.output) == 1
        if len(l.input) == 1:
            coreml_op_to_relay(layerop, l.input[0], l.output[0], etab)
        else:
            coreml_op_to_relay(layerop, list(l.input), l.output[0], etab)

After Change



    // check there are multiple outputs in the model and all are there in etab
    multi_out = all([bool(o.name in etab.exprs) for o in spec.description.output])
    outexpr = _expr.Tuple(outexpr) if multi_out else outexpr[0]

    func = _function.Function(analysis.free_vars(outexpr), outexpr)
    params = {k:_nd.array(np.array(v, dtype=np.float32)) for k, v in etab.params.items()}
    return IRModule.from_expr(func), params
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: apache/incubator-tvm
Commit Name: 4876813c7e094c70c64adeae4a32e7983c7842e1
Time: 2020-08-20
Author: siju.samuel@huawei.com
File Name: python/tvm/relay/frontend/coreml.py
Class Name:
Method Name: from_coreml


Project Name: apache/incubator-tvm
Commit Name: df5ba51e7cd3ad192af95b6a662898132227e185
Time: 2020-12-10
Author: trevmorr@amazon.com
File Name: python/tvm/relay/frontend/pytorch.py
Class Name:
Method Name: from_pytorch


Project Name: sympy/sympy
Commit Name: 491635f0fc00102c6729b704b30f64d1f271be23
Time: 2020-07-13
Author: milan.cs16@iitp.ac.in
File Name: sympy/solvers/ode/ode.py
Class Name:
Method Name: constant_renumber