Skip to content

Commit

Permalink
Update on "[PyTorch Edge] Update iOS readme to use lite interpreter"
Browse files Browse the repository at this point in the history
As lite interpreter moves to beta, it's recommended to let users start using it.

Differential Revision: [D29048350](https://our.internmc.facebook.com/intern/diff/D29048350/)

[ghstack-poisoned]
  • Loading branch information
chenlai committed Jun 22, 2021
2 parents b0b1a87 + 79143a7 commit 13deab1
Show file tree
Hide file tree
Showing 646 changed files with 22,039 additions and 9,062 deletions.
13 changes: 13 additions & 0 deletions .circleci/cimodel/data/pytorch_build_data.py
Expand Up @@ -35,6 +35,11 @@
("10.2", [
("3.6", [
("shard_test", [X(True)]),
("slow_gradcheck", [
(True, [
('shard_test', [XImportant(True)]),
]),
]),
("libtorch", [
(True, [
('build_only', [X(True)]),
Expand Down Expand Up @@ -176,10 +181,18 @@ def child_constructor(self):
"cuda_gcc_override": CudaGccOverrideConfigNode,
"coverage": CoverageConfigNode,
"pure_torch": PureTorchConfigNode,
"slow_gradcheck": SlowGradcheckConfigNode,
}
return next_nodes[experimental_feature]


class SlowGradcheckConfigNode(TreeConfigNode):
def init2(self, node_name):
self.props["is_slow_gradcheck"] = True

def child_constructor(self):
return ExperimentalFeatureConfigNode

class PureTorchConfigNode(TreeConfigNode):
def modify_label(self, label):
return "PURE_TORCH=" + str(label)
Expand Down
16 changes: 12 additions & 4 deletions .circleci/cimodel/data/pytorch_build_definitions.py
Expand Up @@ -258,7 +258,7 @@ def gen_tree():
return configs_list


def instantiate_configs():
def instantiate_configs(only_slow_gradcheck):

config_list = []

Expand All @@ -277,8 +277,12 @@ def instantiate_configs():
is_onnx = fc.find_prop("is_onnx") or False
is_pure_torch = fc.find_prop("is_pure_torch") or False
is_vulkan = fc.find_prop("is_vulkan") or False
is_slow_gradcheck = fc.find_prop("is_slow_gradcheck") or False
parms_list_ignored_for_docker_image = []

if only_slow_gradcheck ^ is_slow_gradcheck:
continue

python_version = None
if compiler_name == "cuda" or compiler_name == "android":
python_version = fc.find_prop("pyver")
Expand Down Expand Up @@ -342,6 +346,10 @@ def instantiate_configs():
if build_only or is_pure_torch:
restrict_phases = ["build"]

if is_slow_gradcheck:
parms_list_ignored_for_docker_image.append("old")
parms_list_ignored_for_docker_image.append("gradcheck")

gpu_resource = None
if cuda_version and cuda_version != "10":
gpu_resource = "medium"
Expand Down Expand Up @@ -381,7 +389,7 @@ def instantiate_configs():
tags_list=RC_PATTERN)
c.dependent_tests = gen_docs_configs(c)

if cuda_version == "10.2" and python_version == "3.6" and not is_libtorch:
if cuda_version == "10.2" and python_version == "3.6" and not is_libtorch and not is_slow_gradcheck:
c.dependent_tests = gen_dependent_configs(c)

if (
Expand All @@ -408,9 +416,9 @@ def instantiate_configs():
return config_list


def get_workflow_jobs():
def get_workflow_jobs(only_slow_gradcheck=False):

config_list = instantiate_configs()
config_list = instantiate_configs(only_slow_gradcheck)

x = []
for conf_options in config_list:
Expand Down
14 changes: 5 additions & 9 deletions .circleci/cimodel/data/windows_build_definitions.py
Expand Up @@ -40,11 +40,13 @@ def gen_tree(self):

target_arch = self.cuda_version.render_dots() if self.cuda_version else "cpu"

python_version = "3.8"

base_name_parts = [
"pytorch",
"windows",
self.vscode_spec.render(),
"py36",
"py" + python_version.replace(".", ""),
target_arch,
]

Expand All @@ -65,7 +67,7 @@ def gen_tree(self):
["pytorch", "win"]
+ self.vscode_spec.get_elements()
+ arch_env_elements
+ ["py3"]
+ ["py" + python_version.split(".")[0]]
)

is_running_on_cuda = bool(self.cuda_version) and not self.force_on_cpu
Expand All @@ -75,7 +77,7 @@ def gen_tree(self):
else:
props_dict = {
"build_environment": build_environment_string,
"python_version": miniutils.quote("3.6"),
"python_version": miniutils.quote(python_version),
"vc_version": miniutils.quote(self.vscode_spec.dotted_version()),
"vc_year": miniutils.quote(str(self.vscode_spec.year)),
"vc_product": self.vscode_spec.get_product(),
Expand Down Expand Up @@ -145,14 +147,8 @@ def render(self):
WORKFLOW_DATA = [
# VS2019 CUDA-10.1
WindowsJob(None, _VC2019, CudaVersion(10, 1), master_only=True),
WindowsJob(1, _VC2019, CudaVersion(10, 1), master_only=True),
WindowsJob(2, _VC2019, CudaVersion(10, 1), master_only=True),
# VS2019 CUDA-10.1 force on cpu
WindowsJob(1, _VC2019, CudaVersion(10, 1), force_on_cpu=True, master_only=True),
# VS2019 CUDA-11.1
WindowsJob(None, _VC2019, CudaVersion(11, 1)),
WindowsJob(1, _VC2019, CudaVersion(11, 1), master_only=True),
WindowsJob(2, _VC2019, CudaVersion(11, 1), master_only=True),

# TODO: This test is disabled due to https://github.com/pytorch/pytorch/issues/59724
# WindowsJob('_azure_multi_gpu', _VC2019, CudaVersion(11, 1), multi_gpu=True, master_and_nightly=True),
Expand Down

0 comments on commit 13deab1

Please sign in to comment.