Skip to content

Commit f2e224c

Browse files
committed
split relative imports into local category
1 parent 705008c commit f2e224c

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

pyproject.toml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,20 @@ categories = [
55
"standard_library",
66
"third_party",
77
"pytorch",
8+
"pytorch_derivatives",
89
"first_party",
9-
"local_test_utils",
1010
]
1111

12+
# This flag is needed to group torchvision into 'pytorch_derivatives' rather than 'first_party'
13+
first_party_detection = false
14+
1215
[tool.usort.known]
1316

1417
pytorch = ["torch"]
15-
first_party = ["torchvision"]
18+
pytorch_derivatives = ["torchvision"]
1619
# These are local utilities in our test/ folder. Since that folder is not a Python package, i.e. test/__init__.py is
1720
# missing, usort mistakes these modules as third party packages.
18-
local_test_utils = [
21+
first_party = [
1922
"_utils_internal",
2023
"common_utils",
2124
"dataset_utils",

0 commit comments

Comments
 (0)