This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"python.pythonPath": "/usr/local/bin/python3", | |
"python.testing.nosetestArgs": [ | |
"tests" | |
], | |
"python.testing.pytestEnabled": false, | |
"python.testing.unittestEnabled": false, | |
"python.testing.nosetestsEnabled": false, | |
"python.testing.promptToConfigure": false, | |
"python.linting.pylintEnabled": true, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"python.pythonPath": "/usr/bin/python3", | |
"python.linting.mypyEnabled": true, | |
"python.linting.pylintEnabled": true, | |
"python.linting.pylintCategorySeverity.convention": "Warning", | |
"python.linting.pylintCategorySeverity.refactor": "Warning", | |
"python.linting.pylintCategorySeverity.warning": "Warning", | |
"python.linting.pylintArgs": [ | |
"--rcfile", | |
"${workspaceRoot}/tests/lint/pylintrc" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import tvm | |
from tvm import relay | |
from tvm.relay.dataflow_pattern import * | |
#class ExtractArgs(tvm.relay.ExprMutator): | |
# # Mutate the graph to replace the matched graph input with new vars. | |
# def __init__(self, mapped_vars): | |
# super(ExtractArgs, self).__init__() | |
# self.mapped_vars = set(mapped_vars) | |
# self.vars = [] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[style] | |
# Align closing bracket with visual indentation. | |
align_closing_bracket_with_visual_indent=True | |
# Allow dictionary keys to exist on multiple lines. For example: | |
# | |
# x = { | |
# ('this is the first element of a tuple', | |
# 'this is the second element of a tuple'): | |
# value, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import tvm | |
from tvm import relay | |
from tvm.contrib import graph_runtime | |
from tvm.relay.backend import compile_engine | |
import gluoncv as gcv | |
model_name = 'MobileNet1.0' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import tvm | |
from tvm import relay | |
from tvm.autotvm.graph_tuner import DPTuner | |
from tvm.contrib import graph_runtime | |
import torch | |
import torchvision |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import tvm | |
from tvm import auto_scheduler, te, topi | |
# The last layer in resnet | |
H, W, CO, CI, KH, KW, strides, padding = 7, 7, 512, 512, 3, 3, (1, 1), (1, 1) | |
def conv2d_diff(N, H, W, CO, CI, KH, KW, stride, padding): | |
data = te.placeholder((N, CI, H, W), name="data") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import numpy as np | |
import logging | |
import tvm | |
from tvm import auto_scheduler, te, topi | |
from tvm.topi.nn.util import get_pad_tuple | |
from tvm.auto_scheduler.compute_dag import ComputeDAG |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extracted_reduction_ax0, extracted_reduction_ax1, extracted_reduction_ax2, extracted_reduction_ax3, extracted_reduction_n0_n0_k1_shifted_shifted, extracted_reduction_n1_n1_k2_shifted_shifted, extracted_reduction_n2_n2_k3_shifted_shifted = tuple(extracted_reduction.op.axis) + tuple(extracted_reduction.op.reduce_axis) | |
pad_temp_data_grad_ax0, pad_temp_data_grad_ax1, pad_temp_data_grad_ax2, pad_temp_data_grad_ax3 = tuple(pad_temp_data_grad.op.axis) + tuple(pad_temp_data_grad.op.reduce_axis) | |
pad_temp_i0, pad_temp_i1, pad_temp_i2, pad_temp_i3 = tuple(pad_temp.op.axis) + tuple(pad_temp.op.reduce_axis) | |
compute_kernel_grad_ax0, compute_kernel_grad_ax1, compute_kernel_grad_ax2, compute_kernel_grad_ax3, compute_kernel_grad_n0_n0_k0_shifted_shifted, compute_kernel_grad_n1_n1_k2_shifted_shifted, compute_kernel_grad_n2_n2_k3_shifted_shifted = tuple(compute_kernel_grad.op.axis) + tuple(compute_kernel_grad.op.reduce_axis) | |
compute_kernel_grad_local, = s.cache_write([compute_kernel_grad], "local") | |
compute_kernel_grad_local_ax0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import logging | |
import numpy as np | |
import tvm | |
from tvm import relay, te, topi, transform, auto_scheduler | |
from tvm.contrib import graph_runtime | |
from tvm.relay.backend import compile_engine | |
# logging.basicConfig(level=logging.INFO) |
OlderNewer