triton-windows 3.3.0a0.post11__cp312-cp312-win_amd64.whl → 3.3.0a0.post12__cp312-cp312-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of triton-windows might be problematic. Click here for more details.
- triton/_C/libtriton.pyd +0 -0
- triton/backends/nvidia/driver.py +4 -4
- triton/windows_utils.py +78 -80
- {triton_windows-3.3.0a0.post11.dist-info → triton_windows-3.3.0a0.post12.dist-info}/METADATA +1 -1
- {triton_windows-3.3.0a0.post11.dist-info → triton_windows-3.3.0a0.post12.dist-info}/RECORD +7 -7
- {triton_windows-3.3.0a0.post11.dist-info → triton_windows-3.3.0a0.post12.dist-info}/WHEEL +0 -0
- {triton_windows-3.3.0a0.post11.dist-info → triton_windows-3.3.0a0.post12.dist-info}/top_level.txt +0 -0
triton/_C/libtriton.pyd
CHANGED
|
Binary file
|
triton/backends/nvidia/driver.py
CHANGED
|
@@ -23,14 +23,14 @@ libraries = ['cuda']
|
|
|
23
23
|
|
|
24
24
|
@functools.lru_cache()
|
|
25
25
|
def libcuda_dirs():
|
|
26
|
-
if os.name == "nt":
|
|
27
|
-
_, _, cuda_lib_dirs = find_cuda()
|
|
28
|
-
return cuda_lib_dirs
|
|
29
|
-
|
|
30
26
|
env_libcuda_path = os.getenv("TRITON_LIBCUDA_PATH")
|
|
31
27
|
if env_libcuda_path:
|
|
32
28
|
return [env_libcuda_path]
|
|
33
29
|
|
|
30
|
+
if os.name == "nt":
|
|
31
|
+
_, _, cuda_lib_dirs = find_cuda()
|
|
32
|
+
return cuda_lib_dirs
|
|
33
|
+
|
|
34
34
|
libs = subprocess.check_output(["/sbin/ldconfig", "-p"]).decode()
|
|
35
35
|
# each line looks like the following:
|
|
36
36
|
# libcuda.so.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libcuda.so.1
|
triton/windows_utils.py
CHANGED
|
@@ -4,6 +4,7 @@ import re
|
|
|
4
4
|
import subprocess
|
|
5
5
|
import sys
|
|
6
6
|
import sysconfig
|
|
7
|
+
import warnings
|
|
7
8
|
import winreg
|
|
8
9
|
from collections.abc import Iterable
|
|
9
10
|
from functools import partial
|
|
@@ -150,7 +151,7 @@ def find_msvc() -> tuple[list[str], list[str]]:
|
|
|
150
151
|
if msvc_base_path is None:
|
|
151
152
|
msvc_base_path, version = find_msvc_hardcoded()
|
|
152
153
|
if msvc_base_path is None:
|
|
153
|
-
|
|
154
|
+
warnings.warn("Failed to find MSVC.")
|
|
154
155
|
return [], []
|
|
155
156
|
|
|
156
157
|
return (
|
|
@@ -216,7 +217,7 @@ def find_winsdk() -> tuple[list[str], list[str]]:
|
|
|
216
217
|
if winsdk_base_path is None:
|
|
217
218
|
winsdk_base_path, version = find_winsdk_hardcoded()
|
|
218
219
|
if winsdk_base_path is None:
|
|
219
|
-
|
|
220
|
+
warnings.warn("Failed to find Windows SDK.")
|
|
220
221
|
return [], []
|
|
221
222
|
|
|
222
223
|
return (
|
|
@@ -250,126 +251,123 @@ def find_python() -> list[str]:
|
|
|
250
251
|
if (python_lib_dir / "python3.lib").exists():
|
|
251
252
|
return [str(python_lib_dir)]
|
|
252
253
|
|
|
253
|
-
|
|
254
|
+
warnings.warn("Failed to find Python libs.")
|
|
254
255
|
return []
|
|
255
256
|
|
|
256
257
|
|
|
257
|
-
def
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
258
|
+
def check_and_find_cuda(base_path: Path) -> tuple[Optional[str], list[str], list[str]]:
|
|
259
|
+
# pip
|
|
260
|
+
if all(
|
|
261
|
+
x.exists()
|
|
262
|
+
for x in [
|
|
263
|
+
base_path / "cuda_nvcc" / "bin" / "ptxas.exe",
|
|
264
|
+
base_path / "cuda_runtime" / "include" / "cuda.h",
|
|
265
|
+
base_path / "cuda_runtime" / "lib" / "x64" / "cuda.lib",
|
|
266
|
+
]
|
|
267
|
+
):
|
|
262
268
|
return (
|
|
263
|
-
str(
|
|
264
|
-
[str(
|
|
265
|
-
[str(
|
|
269
|
+
str(base_path / "cuda_nvcc" / "bin"),
|
|
270
|
+
[str(base_path / "cuda_runtime" / "include")],
|
|
271
|
+
[str(base_path / "cuda_runtime" / "lib" / "x64")],
|
|
266
272
|
)
|
|
267
273
|
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
def check_cuda_pip(nvidia_base_path: Path) -> bool:
|
|
272
|
-
return all(
|
|
274
|
+
# conda
|
|
275
|
+
if all(
|
|
273
276
|
x.exists()
|
|
274
277
|
for x in [
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
+
base_path / "bin" / "ptxas.exe",
|
|
279
|
+
base_path / "include" / "cuda.h",
|
|
280
|
+
base_path / "lib" / "cuda.lib",
|
|
278
281
|
]
|
|
279
|
-
)
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
def find_cuda_pip() -> tuple[Optional[str], list[str], list[str]]:
|
|
283
|
-
nvidia_base_path = Path(sysconfig.get_paths()["platlib"]) / "nvidia"
|
|
284
|
-
if check_cuda_pip(nvidia_base_path):
|
|
282
|
+
):
|
|
285
283
|
return (
|
|
286
|
-
str(
|
|
287
|
-
[str(
|
|
288
|
-
[str(
|
|
284
|
+
str(base_path / "bin"),
|
|
285
|
+
[str(base_path / "include")],
|
|
286
|
+
[str(base_path / "lib")],
|
|
289
287
|
)
|
|
290
288
|
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
def check_cuda_conda(cuda_base_path: Path) -> bool:
|
|
295
|
-
return all(
|
|
289
|
+
# bundled or system-wide
|
|
290
|
+
if all(
|
|
296
291
|
x.exists()
|
|
297
292
|
for x in [
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
293
|
+
base_path / "bin" / "ptxas.exe",
|
|
294
|
+
base_path / "include" / "cuda.h",
|
|
295
|
+
base_path / "lib" / "x64" / "cuda.lib",
|
|
301
296
|
]
|
|
302
|
-
)
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
def find_cuda_conda() -> tuple[Optional[str], list[str], list[str]]:
|
|
306
|
-
cuda_base_path = Path(sys.exec_prefix) / "Library"
|
|
307
|
-
if check_cuda_conda(cuda_base_path):
|
|
297
|
+
):
|
|
308
298
|
return (
|
|
309
|
-
str(
|
|
310
|
-
[str(
|
|
311
|
-
[str(
|
|
299
|
+
str(base_path / "bin"),
|
|
300
|
+
[str(base_path / "include")],
|
|
301
|
+
[str(base_path / "lib" / "x64")],
|
|
312
302
|
)
|
|
313
303
|
|
|
314
304
|
return None, [], []
|
|
315
305
|
|
|
316
306
|
|
|
317
|
-
def
|
|
318
|
-
return all(
|
|
319
|
-
x.exists()
|
|
320
|
-
for x in [
|
|
321
|
-
cuda_base_path / "bin" / "ptxas.exe",
|
|
322
|
-
cuda_base_path / "include" / "cuda.h",
|
|
323
|
-
cuda_base_path / "lib" / "x64" / "cuda.lib",
|
|
324
|
-
]
|
|
325
|
-
)
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
def find_cuda_env() -> Optional[Path]:
|
|
307
|
+
def find_cuda_env() -> tuple[Optional[str], list[str], list[str]]:
|
|
329
308
|
for cuda_base_path in ["CUDA_PATH", "CUDA_HOME"]:
|
|
330
309
|
cuda_base_path = os.getenv(cuda_base_path)
|
|
331
310
|
if cuda_base_path is None:
|
|
332
311
|
continue
|
|
333
312
|
|
|
334
313
|
cuda_base_path = Path(cuda_base_path)
|
|
335
|
-
|
|
336
|
-
|
|
314
|
+
cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs = check_and_find_cuda(
|
|
315
|
+
cuda_base_path
|
|
316
|
+
)
|
|
317
|
+
if cuda_bin_path:
|
|
318
|
+
return cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs
|
|
319
|
+
|
|
320
|
+
return None, [], []
|
|
337
321
|
|
|
338
|
-
return None
|
|
339
322
|
|
|
323
|
+
def find_cuda_bundled() -> tuple[Optional[str], list[str], list[str]]:
|
|
324
|
+
cuda_base_path = (
|
|
325
|
+
Path(sysconfig.get_paths()["platlib"]) / "triton" / "backends" / "nvidia"
|
|
326
|
+
)
|
|
327
|
+
return check_and_find_cuda(cuda_base_path)
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
def find_cuda_pip() -> tuple[Optional[str], list[str], list[str]]:
|
|
331
|
+
nvidia_base_path = Path(sysconfig.get_paths()["platlib"]) / "nvidia"
|
|
332
|
+
return check_and_find_cuda(nvidia_base_path)
|
|
333
|
+
|
|
334
|
+
|
|
335
|
+
def find_cuda_conda() -> tuple[Optional[str], list[str], list[str]]:
|
|
336
|
+
cuda_base_path = Path(sys.exec_prefix) / "Library"
|
|
337
|
+
return check_and_find_cuda(cuda_base_path)
|
|
340
338
|
|
|
341
|
-
|
|
339
|
+
|
|
340
|
+
def find_cuda_hardcoded() -> tuple[Optional[str], list[str], list[str]]:
|
|
342
341
|
parent = find_in_program_files(r"NVIDIA GPU Computing Toolkit\CUDA")
|
|
343
342
|
if parent is None:
|
|
344
|
-
return None
|
|
343
|
+
return None, [], []
|
|
345
344
|
|
|
346
345
|
paths = glob(str(parent / "v12*"))
|
|
347
346
|
# First try the highest version
|
|
348
347
|
paths = sorted(paths)[::-1]
|
|
349
|
-
for
|
|
350
|
-
cuda_base_path = Path(
|
|
351
|
-
|
|
352
|
-
|
|
348
|
+
for cuda_base_path in paths:
|
|
349
|
+
cuda_base_path = Path(cuda_base_path)
|
|
350
|
+
cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs = check_and_find_cuda(
|
|
351
|
+
cuda_base_path
|
|
352
|
+
)
|
|
353
|
+
if cuda_bin_path:
|
|
354
|
+
return cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs
|
|
353
355
|
|
|
354
|
-
return None
|
|
356
|
+
return None, [], []
|
|
355
357
|
|
|
356
358
|
|
|
357
359
|
@functools.cache
|
|
358
360
|
def find_cuda() -> tuple[Optional[str], list[str], list[str]]:
|
|
359
|
-
for f in [
|
|
361
|
+
for f in [
|
|
362
|
+
find_cuda_env,
|
|
363
|
+
find_cuda_bundled,
|
|
364
|
+
find_cuda_pip,
|
|
365
|
+
find_cuda_conda,
|
|
366
|
+
find_cuda_hardcoded,
|
|
367
|
+
]:
|
|
360
368
|
cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs = f()
|
|
361
369
|
if cuda_bin_path:
|
|
362
370
|
return cuda_bin_path, cuda_inc_dirs, cuda_lib_dirs
|
|
363
371
|
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
cuda_base_path = find_cuda_hardcoded()
|
|
367
|
-
if cuda_base_path is None:
|
|
368
|
-
print("WARNING: Failed to find CUDA.")
|
|
369
|
-
return None, [], []
|
|
370
|
-
|
|
371
|
-
return (
|
|
372
|
-
str(cuda_base_path / "bin"),
|
|
373
|
-
[str(cuda_base_path / "include")],
|
|
374
|
-
[str(cuda_base_path / "lib" / "x64")],
|
|
375
|
-
)
|
|
372
|
+
warnings.warn("Failed to find CUDA.")
|
|
373
|
+
return None, [], []
|
|
@@ -3,8 +3,8 @@ triton/_internal_testing.py,sha256=OBY28huiEWItqGgiukgZzHLLaSbS8yj9kdhn_u562Yg,5
|
|
|
3
3
|
triton/_utils.py,sha256=5RiCLwW14w0Q3mdZ-9yz-VO5KiSexNj9xeDt4gaNsvE,1014
|
|
4
4
|
triton/errors.py,sha256=8WfnuRKLG578mgY6cBA3ECruVMf9ULEKFNgRcJ6IhWM,89
|
|
5
5
|
triton/testing.py,sha256=ivFf1Fq9frmfVahaVUp0bgJxmvVZNACZfj3Sai6zfAs,20048
|
|
6
|
-
triton/windows_utils.py,sha256=
|
|
7
|
-
triton/_C/libtriton.pyd,sha256=
|
|
6
|
+
triton/windows_utils.py,sha256=aQMItmuZNXaki8zSB7HMvhy1RsXlmz1GcO-lORm1IIk,10852
|
|
7
|
+
triton/_C/libtriton.pyd,sha256=T7TWmrGlxwXjcNydVakS_wNortpwgHrihL5EiG3sUck,86802944
|
|
8
8
|
triton/backends/__init__.py,sha256=opAo_vgEMt3tLO_bYFrYGksnIu0qohbmyuu_s3-rNAs,1595
|
|
9
9
|
triton/backends/compiler.py,sha256=ymaG0kpveAuESbQ9QZ0RyXjr0Aq4el_G5XGYogJ2gNA,3588
|
|
10
10
|
triton/backends/driver.py,sha256=AN60upJlPgia0JwvZ8vIVgLITNPuI0fdz8zMIIHPpF4,1450
|
|
@@ -114,7 +114,7 @@ triton/backends/amd/lib/ocml.bc,sha256=UPNTXW0gCXUNB-c6orSYwb-mz9_mjUc7zny_vfFza
|
|
|
114
114
|
triton/backends/nvidia/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
115
115
|
triton/backends/nvidia/compiler.py,sha256=zxfzVLLdaH4HLldiM9bG3jXvf3w61gQ6Fkt1CQHQ7lU,18567
|
|
116
116
|
triton/backends/nvidia/driver.c,sha256=-O-Q00SFcCHJiHvArIC7yB10Ma1W8jw7ORFKp7spxHE,18846
|
|
117
|
-
triton/backends/nvidia/driver.py,sha256=
|
|
117
|
+
triton/backends/nvidia/driver.py,sha256=9ZhZTs19M5IU4fAD4JBNhh24MYcP6QLmEMW3SfGgfAQ,20843
|
|
118
118
|
triton/backends/nvidia/bin/ptxas.exe,sha256=iCva9hIYg-Q2NybchwaQJFkwDzNiliFOTDdZrHPLb6A,24732160
|
|
119
119
|
triton/backends/nvidia/include/cuda.h,sha256=Fn44OjeRImxegJ39apYUspseEfTWNGwpqSGUOnHj5WY,1183268
|
|
120
120
|
triton/backends/nvidia/lib/libdevice.10.bc,sha256=XC-uN8huaMOjhgWpX1EtfRLV89uYYxC-R_VzBKpype4,473728
|
|
@@ -157,7 +157,7 @@ triton/tools/link.py,sha256=u7qtfZRLriZkAMEGNvj8YF-k1cthmLL7BwHYqBgT63E,11871
|
|
|
157
157
|
triton/tools/mxfp.py,sha256=YQdpBrGkOVNOtnLeRjMCeVFHWkSwUubGeWsItIjO8TU,11737
|
|
158
158
|
triton/tools/extra/cuda/compile.c,sha256=Me7beHPc6WNTwjg85H84DUMCRu4KJdVK2hNNgvlhBZ4,2126
|
|
159
159
|
triton/tools/extra/cuda/compile.h,sha256=n9QKIFZTL4RSsiXtAxBP9XGSnxjyaevQQ9bBpwDsvAg,332
|
|
160
|
-
triton_windows-3.3.0a0.
|
|
161
|
-
triton_windows-3.3.0a0.
|
|
162
|
-
triton_windows-3.3.0a0.
|
|
163
|
-
triton_windows-3.3.0a0.
|
|
160
|
+
triton_windows-3.3.0a0.post12.dist-info/METADATA,sha256=ZtZEEO2XubX1BJp1mHsG3DTUDMqt2R0z_rYh_K1QAFM,1629
|
|
161
|
+
triton_windows-3.3.0a0.post12.dist-info/WHEEL,sha256=A8mRFNvJcDL8dRPZ6k2ICKEOXwE8pzYFXYxEla0rR0g,101
|
|
162
|
+
triton_windows-3.3.0a0.post12.dist-info/top_level.txt,sha256=KhMzHYsArnZ3IkjAQ-xLnx1n_FjvEpJNelg2xPiDl-U,254
|
|
163
|
+
triton_windows-3.3.0a0.post12.dist-info/RECORD,,
|
|
File without changes
|
{triton_windows-3.3.0a0.post11.dist-info → triton_windows-3.3.0a0.post12.dist-info}/top_level.txt
RENAMED
|
File without changes
|