Repository navigation
Description
Describe the bug
Hi everyone,
I'm trying to execute the code snippet found in the README.md file, however this error message is shown:
C:/Users/Angelo/AppData/Local/Temp/torchinductor_Angelo/pi/cpicxudqmdsjh5cm4klbtbrvy2cxwr7whxl3md2zzdjdf3orvfdf.h(3): fatal error C1083: Cannot open include file: 'algorithm': No such file or directory
I should also mention that 3 weeks ago the very same code snippet worked without any issue. Instead, today it asked me to download Triton, and as such I had to install the package pip install -U 'triton-windows<3.4', as I'm using Windows and Triton is not officially available on this platform.
GPU Info
Output of nvidia-smi:
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 576.02 Driver Version: 576.02 CUDA Version: 12.9 |
|-----------------------------------------+------------------------+----------------------+
| GPU Name Driver-Model | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+========================+======================|
| 0 NVIDIA GeForce RTX 4070 ... WDDM | 00000000:01:00.0 On | N/A |
| N/A 56C P8 2W / 140W | 2657MiB / 8188MiB | 0% Default |
| | | N/A |
+-----------------------------------------+------------------------+----------------------+
Software Info
Operation System/Version: Windows 11 Home 24H2 26100.3775
Python Version: Python 3.11.9
Output of pip show gptqmodel torch transformers accelerate triton:
WARNING: Package(s) not found: triton
Name: gptqmodel
Version: 2.2.0+cu124torch2.5
Summary: Production ready LLM model compression/quantization toolkit with hw accelerated inference support for both cpu/gpu via HF, vLLM, and SGLang.
Home-page: https://github.com/ModelCloud/GPTQModel
Author: ModelCloud
Author-email: [email protected]
License: Apache 2.0
Location: C:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages
Requires:
Required-by:
---
Name: torch
Version: 2.7.0+cu128
Summary: Tensors and Dynamic neural networks in Python with strong GPU acceleration
Home-page: https://pytorch.org/
Author: PyTorch Team
Author-email: [email protected]
License: BSD-3-Clause
Location: C:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages
Requires: filelock, fsspec, jinja2, networkx, sympy, typing-extensions
Required-by: accelerate, torchaudio, torchvision
---
Name: transformers
Version: 4.51.3
Summary: State-of-the-art Machine Learning for JAX, PyTorch and TensorFlow
Home-page: https://github.com/huggingface/transformers
Author: The Hugging Face team (past and future) with the help of all our contributors (https://github.com/huggingface/transformers/graphs/contributors)
Author-email: [email protected]
License: Apache 2.0 License
Location: C:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages
Requires: filelock, huggingface-hub, numpy, packaging, pyyaml, regex, requests, safetensors, tokenizers, tqdm
Required-by: tokenicer
---
Name: accelerate
Version: 1.6.0
Summary: Accelerate
Home-page: https://github.com/huggingface/accelerate
Author: The HuggingFace team
Author-email: [email protected]
License: Apache
Location: C:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages
Requires: huggingface-hub, numpy, packaging, psutil, pyyaml, safetensors, torch
Required-by:
If you are reporting an inference bug of a post-quantized model, please post the content of config.json and quantize_config.json.
config.json:
{
"architectures": [
"LlamaForCausalLM"
],
"attention_bias": false,
"attention_dropout": 0.0,
"bos_token_id": 128000,
"eos_token_id": [
128001,
128008,
128009
],
"head_dim": 64,
"hidden_act": "silu",
"hidden_size": 2048,
"initializer_range": 0.02,
"intermediate_size": 8192,
"max_position_embeddings": 131072,
"mlp_bias": false,
"model_type": "llama",
"num_attention_heads": 32,
"num_hidden_layers": 16,
"num_key_value_heads": 8,
"pretraining_tp": 1,
"quantization_config": {
"bits": 4,
"checkpoint_format": "gptq",
"desc_act": true,
"group_size": 128,
"lm_head": false,
"meta": {
"damp_auto_increment": 0.0025,
"damp_percent": 0.01,
"mse": 0.0,
"quantizer": [
"gptqmodel:2.2.0"
],
"static_groups": false,
"true_sequential": true,
"uri": "https://github.com/modelcloud/gptqmodel"
},
"pack_dtype": "int32",
"quant_method": "gptq",
"sym": true
},
"rms_norm_eps": 1e-05,
"rope_scaling": {
"factor": 32.0,
"high_freq_factor": 4.0,
"low_freq_factor": 1.0,
"original_max_position_embeddings": 8192,
"rope_type": "llama3"
},
"rope_theta": 500000.0,
"tie_word_embeddings": true,
"torch_dtype": "bfloat16",
"transformers_version": "4.51.3",
"use_cache": true,
"vocab_size": 128256
}
quantize_config.json:
{
"bits": 4,
"group_size": 128,
"desc_act": true,
"sym": true,
"lm_head": false,
"quant_method": "gptq",
"checkpoint_format": "gptq",
"pack_dtype": "int32",
"meta": {
"quantizer": [
"gptqmodel:2.2.0"
],
"uri": "https://github.com/modelcloud/gptqmodel",
"damp_percent": 0.01,
"damp_auto_increment": 0.0025,
"static_groups": false,
"true_sequential": true,
"mse": 0.0
}
}
To Reproduce
Execute this code:
from datasets import load_dataset
from gptqmodel import GPTQModel, QuantizeConfig
from gptqmodel.adapter.adapter import Lora
model_id = "meta-llama/Llama-3.2-1B-Instruct"
quant_path = "Llama-3.2-1B-Instruct-gptqmodel-4bit"
calibration_dataset = load_dataset(
"allenai/c4",
data_files="en/c4-train.00001-of-01024.json.gz",
split="train"
).select(range(4))["text"] # 4 sample for quicker test
quant_config = QuantizeConfig(bits=4, group_size=128)
model = GPTQModel.load(model_id, quant_config)
# increase `batch_size` to match gpu/vram specs to speed up quantization
model.quantize(calibration_dataset, batch_size=2)
model.save(quant_path)
model = GPTQModel.load(quant_path)
result = model.generate("Uncovering deep insights begins with")[0] # tokens
print(model.tokenizer.decode(result)) # string output
# higher rank improves accuracy at the cost of vram usage
# suggestion: test rank 64 and 32 before 128 or 256 as latter may overfit while increasing memory usage
eora = Lora(
# for eora generation, path is adapter save path; for load, it is loading path
path=f"{quant_path}/eora_rank32",
rank=32,
)
# provide a previously gptq quantized model path
GPTQModel.adapter.generate( #!!!! THIS IS ALSO THE LINE THAT CAUSES THE ERROR
adapter=eora,
model_id_or_path=model_id,
quantized_model_id_or_path=quant_path,
calibration_dataset=calibration_dataset,
calibration_dataset_concat_size=0,
auto_gc=False)Expected behavior
The program should execute without errors.
Model/Datasets
- Dataset: C4
- "meta-llama/Llama-3.2-1B-Instruct"
Additional Context
Here's the full output of obtained when running the cell containing the GPTQModel.adapter.generate line of code:
---------------------------------------------------------------------------
InductorError Traceback (most recent call last)
Cell In[7], line 2
1 # provide a previously gptq quantized model path
----> 2 GPTQModel.adapter.generate(
3 adapter=eora,
4 model_id_or_path=model_id,
5 quantized_model_id_or_path=quant_path,
6 calibration_dataset=calibration_dataset,
7 calibration_dataset_concat_size=0,
8 auto_gc=False)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\gptqmodel\models\auto.py:628, in GPTQModel.adapter.generate(cls, adapter, model_id_or_path, quantized_model_id_or_path, calibration_dataset, calibration_dataset_concat_size, batch_size, calibration_enable_gpu_cache, tokenizer, logger_board, buffered_fwd, auto_gc, trust_remote_code, torch_dtype)
618 model = GPTQModel.load(
619 model_id_or_path=model_id_or_path,
620 quantize_config=qcfg,
(...) 624 device=CPU,
625 )
627 log.info("Model: Adapter generation started")
--> 628 model._eora_generate(
629 adapter=adapter,
630 quantized_modules=qModules,
631 calibration_dataset=calibration_dataset,
632 calibration_dataset_concat_size=calibration_dataset_concat_size,
633 batch_size=batch_size,
634 calibration_enable_gpu_cache=calibration_enable_gpu_cache,
635 tokenizer=tokenizer,
636 logger_board=logger_board,
637 buffered_fwd=buffered_fwd,
638 auto_gc=auto_gc)
639 return
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\gptqmodel\models\base.py:513, in BaseGPTQModel._eora_generate(self, adapter, quantized_modules, calibration_dataset, calibration_dataset_concat_size, batch_size, calibration_enable_gpu_cache, tokenizer, logger_board, buffered_fwd, auto_gc)
510 # prepare processor worker (looper)
511 module_looper = ModuleLooper(model=self, processors=processors)
--> 513 module_looper.loop(
514 calibration_enable_gpu_cache=calibration_enable_gpu_cache,
515 buffered_fwd=buffered_fwd,
516 auto_gc=auto_gc,
517 )
519 self.eora_save(save_dir=adapter.path, model_save_dir=self.model_local_path)
520 return
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\utils\_contextlib.py:116, in context_decorator.<locals>.decorate_context(*args, **kwargs)
113 @functools.wraps(func)
114 def decorate_context(*args, **kwargs):
115 with ctx_factory():
--> 116 return func(*args, **kwargs)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\gptqmodel\looper\module_looper.py:347, in ModuleLooper.loop(self, auto_gc, calibration_enable_gpu_cache, buffered_fwd, **kwargs)
345 for name_index, name in enumerate(subset):
346 m = subset[name]
--> 347 processor.process(module=m)
348 processed_subset[name] = m
350 if index == len(layer_modules) - 1:
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\gptqmodel\looper\dequantize_processor.py:47, in DequantizeProcessor.process(self, module)
45 m.optimize()
46 log.info(f"Dequantize: `{m.name}`")
---> 47 wq = m.dequantize_weight().T.to(device=device)
49 module.state.update({
50 "w": w,
51 "wq": wq,
52 })
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_dynamo\eval_frame.py:663, in _TorchDynamoContext.__call__.<locals>._fn(*args, **kwargs)
659 raise e.with_traceback(None) from None
660 except ShortenTraceback as e:
661 # Failures in the backend likely don't have useful
662 # data in the TorchDynamo frames, so we strip them out.
--> 663 raise e.remove_dynamo_frames() from None # see TORCHDYNAMO_VERBOSE=1
664 finally:
665 # Restore the dynamic layer stack depth if necessary.
666 set_eval_frame(None)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\compile_fx.py:760, in _compile_fx_inner(gm, example_inputs, **graph_kwargs)
758 raise
759 except Exception as e:
--> 760 raise InductorError(e, currentframe()).with_traceback(
761 e.__traceback__
762 ) from None
763 finally:
764 TritonBundler.end_compile()
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\compile_fx.py:745, in _compile_fx_inner(gm, example_inputs, **graph_kwargs)
743 TritonBundler.begin_compile()
744 try:
--> 745 mb_compiled_graph = fx_codegen_and_compile(
746 gm, example_inputs, inputs_to_check, **graph_kwargs
747 )
748 assert mb_compiled_graph is not None
749 mb_compiled_graph._time_taken_ns = time.time_ns() - start_time
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\compile_fx.py:1295, in fx_codegen_and_compile(gm, example_inputs, inputs_to_check, **graph_kwargs)
1291 from .compile_fx_subproc import _SubprocessFxCompile
1293 scheme = _SubprocessFxCompile()
-> 1295 return scheme.codegen_and_compile(gm, example_inputs, inputs_to_check, graph_kwargs)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\compile_fx.py:1197, in _InProcessFxCompile.codegen_and_compile(self, gm, example_inputs, inputs_to_check, graph_kwargs)
1184 compiled_fn = AotCodeCompiler.compile(
1185 graph,
1186 wrapper_code.value,
(...) 1194 ],
1195 )
1196 else:
-> 1197 compiled_fn = graph.compile_to_module().call
1199 num_bytes, nodes_num_elem, node_runtimes = graph.count_bytes()
1200 metrics.num_bytes_accessed += num_bytes
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\graph.py:2083, in GraphLowering.compile_to_module(self)
2076 def compile_to_module(self) -> ModuleType:
2077 with dynamo_timed(
2078 "GraphLowering.compile_to_module",
2079 phase_name="code_gen",
2080 log_pt2_compile_event=True,
2081 dynamo_compile_column_us="inductor_code_gen_cumulative_compile_time_us",
2082 ):
-> 2083 return self._compile_to_module()
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\graph.py:2130, in GraphLowering._compile_to_module(self)
2124 trace_structured(
2125 "inductor_output_code",
2126 lambda: {"filename": path},
2127 payload_fn=lambda: wrapper_code.value,
2128 )
2129 with dynamo_timed("PyCodeCache.load_by_key_path", log_pt2_compile_event=True):
-> 2130 mod = PyCodeCache.load_by_key_path(
2131 key,
2132 path,
2133 linemap=linemap, # type: ignore[arg-type]
2134 attrs={**self.constants, **self.torchbind_constants},
2135 )
2136 self.cache_key = key
2137 self.cache_path = path
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\codecache.py:2747, in PyCodeCache.load_by_key_path(cls, key, path, linemap, attrs)
2744 if linemap is None:
2745 linemap = []
-> 2747 mod = _reload_python_module(key, path)
2749 # unzip into separate lines/nodes lists
2750 cls.linemaps[path] = list(zip(*linemap))
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\runtime\compile_tasks.py:36, in _reload_python_module(key, path)
34 mod.__file__ = path
35 mod.key = key # type: ignore[attr-defined]
---> 36 exec(code, mod.__dict__, mod.__dict__)
37 sys.modules[mod.__name__] = mod
38 return mod
File ~\AppData\Local\Temp\torchinductor_Angelo\ex\cex5sf4rudle7v2tharyy6bw5enkqafl4zsexbwhrx4kfpyseq47.py:31
27 async_compile = AsyncCompile()
28 empty_strided_p2p = torch._C._distributed_c10d._SymmetricMemory.empty_strided_p2p
---> 31 cpp_fused_index_mul_sub_0 = async_compile.cpp_pybinding(['const int32_t*', 'const bfloat16*', 'const int32_t*', 'const int32_t*', 'const int32_t*', 'const int32_t*', 'bfloat16*'], '''
32 #include "C:/Users/Angelo/AppData/Local/Temp/torchinductor_Angelo/pi/cpicxudqmdsjh5cm4klbtbrvy2cxwr7whxl3md2zzdjdf3orvfdf.h"
33 extern "C" __declspec(dllexport) void kernel(const int32_t* in_ptr0,
34 const bfloat16* in_ptr1,
35 const int32_t* in_ptr2,
36 const int32_t* in_ptr3,
37 const int32_t* in_ptr4,
38 const int32_t* in_ptr5,
39 bfloat16* out_ptr0)
40 {
41 {
42 for(int64_t x0=static_cast<int64_t>(0LL); x0<static_cast<int64_t>(2048LL); x0+=static_cast<int64_t>(1LL))
43 {
44 for(int64_t x1=static_cast<int64_t>(0LL); x1<static_cast<int64_t>(512LL); x1+=static_cast<int64_t>(1LL))
45 {
46 {
47 {
48 auto tmp0 = in_ptr0[static_cast<int64_t>(x0)];
49 auto tmp12 = in_ptr2[static_cast<int64_t>(x1 + 512LL*(c10::div_floor_integer(static_cast<int64_t>(x0), static_cast<int64_t>(8LL))))];
50 auto tmp13 = in_ptr3[static_cast<int64_t>((static_cast<int64_t>(x0) % static_cast<int64_t>(8LL)))];
51 auto tmp19 = in_ptr5[static_cast<int64_t>((static_cast<int64_t>(x1) % static_cast<int64_t>(8LL)))];
52 auto tmp1 = c10::convert<int64_t>(tmp0);
53 auto tmp2 = 16LL;
54 auto tmp3 = c10::convert<int64_t>(tmp2);
55 auto tmp4 = decltype(tmp1)(tmp1 + tmp3);
56 auto tmp5 = tmp1 < 0;
57 auto tmp6 = tmp5 ? tmp4 : tmp1;
58 auto tmp7 = tmp6;
59 auto tmp8 = c10::convert<int64_t>(tmp7);
60 TORCH_CHECK((0 <= tmp8) & (tmp8 < 16LL), "index out of bounds: 0 <= tmp8 < 16LL");
61 auto tmp10 = in_ptr1[static_cast<int64_t>(x1 + 512LL*tmp6)];
62 auto tmp11 = c10::convert<float>(tmp10);
63 auto tmp14 =
64 [&]()
65 {
66 constexpr decltype(tmp13) max_shift = sizeof(int32_t) * CHAR_BIT - std::is_signed_v<int32_t>;
67 if ((static_cast<std::make_signed_t<int32_t>>(tmp13) < 0) || (tmp13 >= max_shift))
68 {
69 return decltype(tmp12)(tmp12 >> max_shift);
70 }
71 return decltype(tmp12)(tmp12 >> tmp13);
72 }
73 ()
74 ;
75 auto tmp15 = c10::convert<int8_t>(tmp14);
76 auto tmp16 = static_cast<int8_t>(15);
77 auto tmp17 = decltype(tmp15)(tmp15 & tmp16);
78 auto tmp18 = in_ptr4[static_cast<int64_t>(64LL*tmp6 + (c10::div_floor_integer(static_cast<int64_t>(x1), static_cast<int64_t>(8LL))))];
79 auto tmp20 =
80 [&]()
81 {
82 constexpr decltype(tmp19) max_shift = sizeof(int32_t) * CHAR_BIT - std::is_signed_v<int32_t>;
83 if ((static_cast<std::make_signed_t<int32_t>>(tmp19) < 0) || (tmp19 >= max_shift))
84 {
85 return decltype(tmp18)(tmp18 >> max_shift);
86 }
87 return decltype(tmp18)(tmp18 >> tmp19);
88 }
89 ()
90 ;
91 auto tmp21 = c10::convert<int8_t>(tmp20);
92 auto tmp22 = decltype(tmp21)(tmp21 & tmp16);
93 auto tmp23 = decltype(tmp17)(tmp17 - tmp22);
94 auto tmp24 = c10::convert<float>(tmp23);
95 auto tmp25 = decltype(tmp11)(tmp11 * tmp24);
96 auto tmp26 = c10::convert<bfloat16>(tmp25);
97 out_ptr0[static_cast<int64_t>(x1 + 512LL*x0)] = tmp26;
98 }
99 }
100 }
101 }
102 }
103 }
104 ''')
107 async_compile.wait(globals())
108 del async_compile
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\async_compile.py:370, in AsyncCompile.cpp_pybinding(self, argtypes, source_code)
368 kernel_code_log.info("CPP+Bindings Kernel:\n%s", source_code)
369 if get_compile_threads() <= 1:
--> 370 return CppPythonBindingsCodeCache.load_pybinding(argtypes, source_code)
371 else:
372 get_result = CppPythonBindingsCodeCache.load_pybinding_async(
373 argtypes, source_code, submit_fn=self.submit
374 )
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\codecache.py:2250, in CppPythonBindingsCodeCache.load_pybinding(cls, *args, **kwargs)
2248 @classmethod
2249 def load_pybinding(cls, *args: Any, **kwargs: Any) -> Any:
-> 2250 return cls.load_pybinding_async(*args, **kwargs)()
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\codecache.py:2242, in CppPythonBindingsCodeCache.load_pybinding_async.<locals>.future()
2240 nonlocal result
2241 if result is None:
-> 2242 result = get_result()
2243 assert isinstance(result, ModuleType)
2244 return getattr(result, cls.entry_function)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\codecache.py:2051, in CppCodeCache.load_async.<locals>.load_fn()
2049 if future is not None:
2050 future.result()
-> 2051 result = worker_fn()
2052 assert result is None
2053 lib = cls._load_library(binary_path, key)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\codecache.py:2079, in _worker_compile_cpp(lock_path, cpp_builder)
2077 with FileLock(lock_path, timeout=LOCK_TIMEOUT):
2078 if not os.path.exists(cpp_builder.get_target_file_path()):
-> 2079 cpp_builder.build()
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\cpp_builder.py:1601, in CppBuilder.build(self)
1598 _create_if_dir_not_exist(_build_tmp_dir)
1600 build_cmd = self.get_command_line()
-> 1601 run_compile_cmd(build_cmd, cwd=_build_tmp_dir)
1602 _remove_dir(_build_tmp_dir)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\cpp_builder.py:355, in run_compile_cmd(cmd_line, cwd)
353 def run_compile_cmd(cmd_line: str, cwd: str) -> None:
354 with dynamo_timed("compile_file"):
--> 355 _run_compile_cmd(cmd_line, cwd)
File c:\Users\Angelo\Desktop\franken-tesi\.venv\Lib\site-packages\torch\_inductor\cpp_builder.py:350, in _run_compile_cmd(cmd_line, cwd)
340 instruction = (
341 "\n\nOpenMP support not found. Please try one of the following solutions:\n"
342 "(1) Set the `CXX` environment variable to a compiler other than Apple clang++/g++ "
(...) 347 " with `include/omp.h` under it."
348 )
349 output += instruction
--> 350 raise exc.CppCompileError(cmd, output) from e
InductorError: CppCompileError: C++ compile error
Command:
cl /I C:/Users/Angelo/AppData/Local/Programs/Python/Python311/Include /I c:/Users/Angelo/Desktop/franken-tesi/.venv/Lib/site-packages/torch/include /I c:/Users/Angelo/Desktop/franken-tesi/.venv/Lib/site-packages/torch/include/torch/csrc/api/include /D TORCH_INDUCTOR_CPP_WRAPPER /D STANDALONE_TORCH_HEADER /D C10_USING_CUSTOM_GENERATED_MACROS /DLL /MD /O2 /std:c++20 /wd4819 /wd4251 /wd4244 /wd4267 /wd4275 /wd4018 /wd4190 /wd4624 /wd4067 /wd4068 /EHsc /openmp /openmp:experimental C:/Users/Angelo/AppData/Local/Temp/torchinductor_Angelo/op/copelvgsuh7mlq4mgih6xnqlnkegpa4um32k4nmdsumzjyewjy2q.cpp /LD /FeC:/Users/Angelo/AppData/Local/Temp/torchinductor_Angelo/op/copelvgsuh7mlq4mgih6xnqlnkegpa4um32k4nmdsumzjyewjy2q.pyd /link /LIBPATH:C:/Users/Angelo/AppData/Local/Programs/Python/Python311/libs /LIBPATH:c:/Users/Angelo/Desktop/franken-tesi/.venv/Lib/site-packages/torch/lib torch.lib torch_cpu.lib torch_python.lib sleef.lib
Output:
Microsoft (R) C/C++ Optimizing Compiler Version 19.43.34809 for x64
Copyright (C) Microsoft Corporation. All rights reserved.
cl : Command line warning D9025 : overriding '/openmp' with '/openmp:experimental'
copelvgsuh7mlq4mgih6xnqlnkegpa4um32k4nmdsumzjyewjy2q.cpp
C:/Users/Angelo/AppData/Local/Temp/torchinductor_Angelo/pi/cpicxudqmdsjh5cm4klbtbrvy2cxwr7whxl3md2zzdjdf3orvfdf.h(3): fatal error C1083: Cannot open include file: 'algorithm': No such file or directory
Set TORCHDYNAMO_VERBOSE=1 for the internal stack trace (please do this especially if you're reporting a bug to PyTorch). For even more developer context, set TORCH_LOGS="+dynamo"
Activity
Qubitium commentedon Apr 30, 2025
@AngeloGalav Windows native support is currently alpha quality due to horrendous driver/cuda depend issues. Please use WSL2 linux subsystem under windows. This will fix all your future headaches on Windows. WSL2 has full 100% performance on Windows versus native windows with none of the windows baggage.
I also see that you have the bleeding edge Nvidia driver
cuda 12.9so triton may not even be compatible with this and can't find it.AngeloGalav commentedon Apr 30, 2025
@Qubitium thank you for the very fast response, I'm now going to try to downgrade my CUDA version just for testing purposes to see if it really is the culprit, then I'm going to switch to WSL2 like you suggested since it seems like the best idea anyways.
AngeloGalav commentedon Apr 30, 2025
Just for update, I run everything with WSL2 and it worked without a itch.
As for downgrading CUDA, it did not seem like a possibility without downgrading the whole GPU driver.