Skip to content

Commit

Permalink
added isinstance elif incase variable isn't a tensor
Browse files Browse the repository at this point in the history
  • Loading branch information
costigt-dev committed May 1, 2024
1 parent 28e8868 commit 165b8de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/brevitas/nn/mixin/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def unpack_input(self, inp: Union[Tensor, QuantTensor]) -> Union[Tensor, QuantTe
if not torch._C._get_tracing_state():
if isinstance(inp, QuantTensor):
inp = inp.set(value=inp.value.rename(None))
else:
elif isinstance(inp, Tensor):
inp = inp.rename(None)
return inp

Expand Down

0 comments on commit 165b8de

Please sign in to comment.