Dynamo or FakeTensor bug: reshape(): argument 'shape' (position 1) must be tuple of ints, but found element of type FakeTensor at pos 0
Labels: triaged, oncall: pt2, module: fakeTensor, module: dynamo

### 🐛 Describe the bug

Repo
```
import torch
import torch._dynamo
import numpy as np

class MyModule(torch.nn.Linear):

    def __init__(self):
        super().__init__(np.array([4, 4, 1]).prod(), np.array([4, 4, 1]).prod())

    def forward(self, x):
        # return x.reshape(1, self.in_features). # This line passed
        return x.reshape(self.in_features)

x = torch.rand([4, 4])
model = MyModule()
print(model(x))
opt_model = torch._dynamo.optimize("eager")(model)
print(opt_model(x))
```
I think this is because we wrap ```self.in_features``` as ```UnspecializedPythonVariable```, and it becomes ```FakeTensor```. We are trying to dispatch to a ```reshape``` function with signature ```FakeTensor``` and failed. But the wired thing is, it passed if I switched to the commented line.

Error
```
Traceback (most recent call last):
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 1196, in run_node
    return getattr(args[0], node.target)(*args[1:], **kwargs)
TypeError: reshape(): argument 'shape' (position 1) must be tuple of ints, but found element of type FakeTensor at pos 0

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 1152, in get_fake_value
    return wrap_fake_exception(
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 808, in wrap_fake_exception
    return fn()
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 1153, in <lambda>
    lambda: run_node(tx.output, node, args, kwargs, nnmodule)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 1206, in run_node
    raise RuntimeError(
RuntimeError: Failed running call_method reshape(*(FakeTensor(FakeTensor(..., device='meta', size=(4, 4)), cpu), FakeTensor(FakeTensor(..., device='meta', size=(), dtype=torch.int64), cpu)), **{}):
reshape(): argument 'shape' (position 1) must be tuple of ints, but found element of type FakeTensor at pos 0
(scroll up for backtrace)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/scratch/ybliang/work/repos/pytorch/debug/debug1.py", line 51, in <module>
    print(opt_model(x))
  File "/scratch/ybliang/work/repos/pytorch/torch/nn/modules/module.py", line 1501, in _call_impl
    return forward_call(*args, **kwargs)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/eval_frame.py", line 82, in forward
    return self.dynamo_ctx(self._orig_mod.forward)(*args, **kwargs)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/eval_frame.py", line 209, in _fn
    return fn(*args, **kwargs)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/eval_frame.py", line 337, in catch_errors
    return callback(frame, cache_size, hooks)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/convert_frame.py", line 404, in _convert_frame
    result = inner_convert(frame, cache_size, hooks)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/convert_frame.py", line 104, in _fn
    return fn(*args, **kwargs)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/convert_frame.py", line 262, in _convert_frame_assert
    return _compile(
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 163, in time_wrapper
    r = func(*args, **kwargs)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/convert_frame.py", line 324, in _compile
    out_code = transform_code_object(code, transform)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/bytecode_transformation.py", line 530, in transform_code_object
    transformations(instructions, code_options)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/convert_frame.py", line 311, in transform
    tracer.run()
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 1862, in run
    super().run()
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 619, in run
    and self.step()
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 583, in step
    getattr(self, inst.opname)(inst)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 349, in wrapper
    return inner_fn(self, inst)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 1014, in CALL_FUNCTION
    self.call_function(fn, args, {})
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/symbolic_convert.py", line 517, in call_function
    self.push(fn.call_function(self, args, kwargs))
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/variables/misc.py", line 744, in call_function
    return self.obj.call_method(tx, self.name, args, kwargs).add_options(self)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/variables/tensor.py", line 424, in call_method
    return wrap_fx_proxy(
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/variables/builder.py", line 754, in wrap_fx_proxy
    return wrap_fx_proxy_cls(
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/variables/builder.py", line 789, in wrap_fx_proxy_cls
    example_value = get_fake_value(proxy.node, tx)
  File "/scratch/ybliang/work/repos/pytorch/torch/_dynamo/utils.py", line 1173, in get_fake_value
    raise TorchRuntimeError() from e
torch._dynamo.exc.TorchRuntimeError: 

from user code:
   File "/scratch/ybliang/work/repos/pytorch/debug/debug1.py", line 43, in forward
    return x.reshape(self.in_features)


You can suppress this exception and fall back to eager by setting:
    torch._dynamo.config.suppress_errors = True
```

### Versions

N/A

cc @ezyang @soumith @msaroufim @wconstab @ngimel @bdhirsh @voznesenskym @penguinwu @anijain2305 @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @Xia-Weiwen @wenzhe-nrv @jiayisunx @desertfire