You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to run NNSmith on TorchJIT, I encountered errors like
ERROR fuzz - `make_testcase` failed with seed 1412986392. It can be NNSmith or Generator (torch) bug.
ERROR fuzz - Traceback (most recent call last):
File "nnsmith/cli/fuzz.py", line 215, in run
testcase = self.make_testcase(seed)
File "nnsmith/cli/fuzz.py", line 187, in make_testcase
model.refine_weights() # either random generated or gradient-based.
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/__init__.py", line 40, in refine_weights
_, inputs = searcher.search(
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/input_gen.py", line 56, in search
res = self.search_one(cur_input, max_time_ms)
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/input_gen.py", line 110, in search_one
return SamplingSearch.search_one(self, start_inp, timeout_ms)
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/input_gen.py", line 70, in search_one
_ = self.net(**start_inp)
File "/home/su/accdiff/thirdparty/pytorch/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/symbolnet.py", line 341, in forward
output_tensors = inst(*input_tensors)
File "/home/su/accdiff/thirdparty/pytorch/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/proxy_grad.py", line 108, in forward
return PGReLUFunc.apply(x)
File "/home/su/accdiff/thirdparty/pytorch/torch/autograd/function.py", line 506, in apply
return super().apply(*args, **kwargs) # type: ignore[misc]
File "/home/su/accdiff/thirdparty/nnsmith/nnsmith/materialize/torch/proxy_grad.py", line 40, in forward
return torch.relu(input)
RuntimeError: "clamp_min_scalar_cpu" not implemented for 'Half'
Unfortunately, I still can't run it with float16 on GPU. I'm wondering if model.refine_weights() should be executed on GPU since many half-precision operators are not supported on CPU.
@soodoshll Apologies for the delay. We should be able to use backend.target=cuda now. Thanks for reporting and please let me know if there are any other issues!
Description
Hi!
When trying to run NNSmith on TorchJIT, I encountered errors like
Installation
Source file without edits
Reproduction
yes | python nnsmith/cli/fuzz.py --config-dir nnsmith/config/ model.type=torch backend.type=torchjit fuzz.root=fuzz_report debug.viz=true backend.target=cuda
Screenshots

Logs
No response
Front-end framework
No response
Version of the front-end framework
torch-2.0.0a0+git062380d
Back-end engine
torchjit
Version of the front-end engine
No response
Other context
No response
The text was updated successfully, but these errors were encountered: