Skip to content

Bloom_code.py forward method fails at aten.lift_fresh_copy.default(_tensor_constant0, ) because _tensor_constant0 is not a Tensor #743

Open
@amalbasaTT

Description

@amalbasaTT

Ticket
Link to Github Issue

Describe the bug
forward function in Bloom_code.py file which is generated from running pytest tests/models/bloom/test_bloom.py --gen_op_accuracy_tests fails at 110. line of code lift_fresh_copy = aten.lift_fresh_copy.default(_tensor_constant0, ). lift_fresh_copy requires it's input to be Tensor and not float.

To Reproduce
Steps to reproduce the behavior:

  1. Install torch-ttnn as explained in https://github.com/tenstorrent/pytorch2.0_ttnn?tab=readme-ov-file
  2. Possition to pytorch2.0_ttnn directory
  3. Generate Bloom_code.py and Bloom_inputs.pickle by running command:
pytest tests/models/bloom/test_bloom.py --gen_op_accuracy_tests
  1. Run Bloom_code.py:
python3 tests/autogen_accuracy_tests/Bloom_code.py

Error will be at 110. line of code:

Traceback (most recent call last):
File "/home/ubuntu/pytorch2.0_ttnn/tests/autogen_accuracy_tests/Bloom_code.py", line 5866, in
forward(*inputs)
File "/home/ubuntu/pytorch2.0_ttnn/tests/autogen_accuracy_tests/Bloom_code.py", line 110, in forward
lift_fresh_copy = aten.lift_fresh_copy.default(_tensor_constant0, )
File "/home/ubuntu/tt-metal/python_env/lib/python3.8/site-packages/torch/_ops.py", line 513, in call
return self._op(*args, **(kwargs or {}))
RuntimeError: aten::lift_fresh_copy() Expected a value of type 'Tensor' for argument 'self' but instead found type 'float'.
Position: 0
Value: 0.7071067690849304
Declaration: aten::lift_fresh_copy(Tensor self) -> Tensor
Cast error details: Unable to cast 0.7071067690849304 to Tensor

Metadata

Metadata

Assignees

Labels

Type

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions