Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions install_requirements.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@ def clean():
print("Done cleaning build artifacts.")


VALID_PYBINDS = ["coreml", "mps", "xnnpack"]


# The pip repository that hosts nightly torch packages.
TORCH_NIGHTLY_URL = "https://download.pytorch.org/whl/nightly/cpu"

Expand Down Expand Up @@ -120,8 +123,6 @@ def install_requirements(use_pytorch_nightly):
"pip",
"install",
"-r",
"requirements-dev.txt",
"-r",
"requirements-examples.txt",
*REQUIREMENTS_TO_INSTALL,
"--extra-index-url",
Expand Down Expand Up @@ -190,8 +191,10 @@ def main(args):
EXECUTORCH_BUILD_PYBIND = "OFF"
else:
for pybind_arg in args.pybind:
if pybind_arg not in ["coreml", "mps", "xnnpack"]:
continue
if pybind_arg not in VALID_PYBINDS:
raise Exception(
f"Unrecognized pybind argument {pybind_arg}; valid options are: {", ".join(VALID_PYBINDS)}"
)
EXECUTORCH_BUILD_PYBIND = "ON"
CMAKE_ARGS += f" -DEXECUTORCH_BUILD_{pybind_arg.upper()}=ON"

Expand Down
2 changes: 0 additions & 2 deletions requirements-dev.txt

This file was deleted.