5619f0a742cfee882b51b6798215362e227c2732,tensorboardX/graph.py,,parse,#Any#,14
Before Change
for n in graph.nodes():
attrs = {k: n[k] for k in n.attributeNames()}
attrs = str(attrs).replace(""", " ") // singlequote will be escaped by tensorboard
if any(i.uniqueName() not in scope.keys() for i in n.inputs() ): // 0.3.1 workaround
continue
inputs = [replace(i.uniqueName(), scope) for i in n.inputs()]
outputnode = next(iter(n.outputs())) // FIXME: only first output is considered
After Change
mapping[n["name"]] = scope[n["name"]] + "/" + \
n["op"].replace("onnx::", "") + "_" + n["name"]
for n in nodes:
n["name"] = mapping[n["name"]]
for i, s in enumerate(n["inputs"]):
n["inputs"][i] = mapping[s]
return nodes
def graph(model, args, verbose=False):
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 4
Instances Project Name: lanpa/tensorboardX
Commit Name: 5619f0a742cfee882b51b6798215362e227c2732
Time: 2018-04-28
Author: huang.dexter@gmail.com
File Name: tensorboardX/graph.py
Class Name:
Method Name: parse
Project Name: Microsoft/nni
Commit Name: f7b7edac5b9e329ffdda30d710f68db71d08e065
Time: 2020-11-22
Author: 38930155+chicm-ms@users.noreply.github.com
File Name: nni/common/graph_utils.py
Class Name: TorchModuleGraph
Method Name: _build_graph
Project Name: HyperGAN/HyperGAN
Commit Name: a1acf506862f847a244b9cc07fb1f32505c81003
Time: 2018-07-10
Author: mikkel@255bits.com
File Name: hypergan/trainers/gang_trainer.py
Class Name: GangTrainer
Method Name: fitness_score
Project Name: hyperopt/hyperopt
Commit Name: 7fe4041f146b5948a674fd404e80e531022967dd
Time: 2012-04-11
Author: james.bergstra@gmail.com
File Name: hyperopt/vectorize.py
Class Name: VectorizeHelper
Method Name: build_idxs_vals