Unsupported: ONNX export of operator interpolate (with scales) error
Labels: module: onnx, triaged

### 🐛 Describe the bug

Trying to run onnx export of a scripted model.
I guess it can't figure out the shape of the tensor for interpolate?
It's hard to give a reproducible test case without sending the whole model.

It's also hard to debug this since there's no hint as to which interpolate (of the several that we have in the network) that it's complaining about.

See this stack trace:
```
/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py:825: UserWarning: no signature found for <torch.ScriptMethod object at 0x7f238781f290>, skipping _decide_input_format
  warnings.warn(f"{e}, skipping _decide_input_format")
================ Diagnostic Run torch.onnx.export version 2.0.1 ================
verbose: False, log level: Level.ERROR
======================= 0 NONE 0 NOTE 0 WARNING 0 ERROR ========================

Traceback (most recent call last):
  File "/home/go22670/Projects/test2/convert.py", line 21, in <module>
    out, vad, enhFile = enh.process(file,outFile=myout)
  File "/home/go22670/Projects/test2/src/seamnet/enhance.py", line 278, in process
    self.convert(self.model, tWin)
  File "/home/go22670/Projects/test2/src/seamnet/enhance.py", line 206, in convert
    Th.onnx.export(model,
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 506, in export
    _export(
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 1548, in _export
    graph, params_dict, torch_out = _model_to_graph(
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 1117, in _model_to_graph
    graph = _optimize_graph(
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 665, in _optimize_graph
    graph = _C._jit_pass_onnx(graph, operator_export_type)
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 1891, in _run_symbolic_function
    return symbolic_fn(graph_context, *inputs, **attrs)
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_opset9.py", line 6709, in prim_loop
    torch._C._jit_pass_onnx_block(
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/utils.py", line 1891, in _run_symbolic_function
    return symbolic_fn(graph_context, *inputs, **attrs)
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_helper.py", line 392, in wrapper
    return fn(g, *args, **kwargs)
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_opset11.py", line 391, in __interpolate
    return symbolic_helper.__interpolate_helper(
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_helper.py", line 1212, in __interpolate_helper
    return _unimplemented("interpolate (with scales)", "missing input shape")
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_helper.py", line 607, in _unimplemented
    _onnx_unsupported(f"{op}, {msg}", value)
  File "/home/go22670/.conda/envs/torch/lib/python3.10/site-packages/torch/onnx/symbolic_helper.py", line 622, in _onnx_unsupported
    raise errors.OnnxExporterError(message)
torch.onnx.errors.OnnxExporterError: Unsupported: ONNX export of operator interpolate (with scales), missing input shape. Please feel free to request support or submit a pull request on PyTorch GitHub: https://github.com/pytorch/pytorch/issues
```

### Versions

(torch) [go22670@nti-rh8-gpu test2]$ python collect_env.py
Collecting environment information...
PyTorch version: 2.0.1
Is debug build: False
CUDA used to build PyTorch: 11.8
ROCM used to build PyTorch: N/A

OS: Red Hat Enterprise Linux 8.7 (Ootpa) (x86_64)
GCC version: (GCC) 8.5.0 20210514 (Red Hat 8.5.0-15)
Clang version: Could not collect
CMake version: version 3.20.2
Libc version: glibc-2.28

Python version: 3.10.11 (main, Apr 20 2023, 19:02:41) [GCC 11.2.0] (64-bit runtime)
Python platform: Linux-4.18.0-425.3.1.el8.x86_64-x86_64-with-glibc2.28
Is CUDA available: True
CUDA runtime version: 11.1.105
CUDA_MODULE_LOADING set to: LAZY
GPU models and configuration: 
GPU 0: GRID A100-40C
GPU 1: GRID A100-40C

Nvidia driver version: 510.85.02
cuDNN version: Could not collect
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

CPU:
Architecture:        x86_64
CPU op-mode(s):      32-bit, 64-bit
Byte Order:          Little Endian
CPU(s):              16
On-line CPU(s) list: 0-15
Thread(s) per core:  1
Core(s) per socket:  2
Socket(s):           8
NUMA node(s):        1
Vendor ID:           AuthenticAMD
CPU family:          25
Model:               1
Model name:          AMD EPYC 7713 64-Core Processor
Stepping:            1
CPU MHz:             1996.249
BogoMIPS:            3992.49
Hypervisor vendor:   VMware
Virtualization type: full
L1d cache:           32K
L1i cache:           32K
L2 cache:            512K
L3 cache:            32768K
NUMA node0 CPU(s):   0-15
Flags:               fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl tsc_reliable nonstop_tsc cpuid extd_apicid pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm cmp_legacy extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw topoext invpcid_single ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 invpcid rdseed adx smap clflushopt clwb sha_ni xsaveopt xsavec xgetbv1 xsaves clzero wbnoinvd arat umip pku ospke vaes vpclmulqdq rdpid overflow_recov succor

Versions of relevant libraries:
[pip3] numpy==1.23.5
[pip3] torch==2.0.1
[pip3] torchaudio==2.0.2
[pip3] torchview==0.2.6
[pip3] torchvision==0.15.2
[pip3] triton==2.0.0
[conda] blas                      1.0                         mkl  
[conda] ffmpeg                    4.3                  hf484d3e_0    pytorch
[conda] mkl                       2021.4.0           h06a4308_640  
[conda] mkl-fft                   1.3.1                    pypi_0    pypi
[conda] mkl-random                1.2.2                    pypi_0    pypi
[conda] mkl-service               2.4.0                    pypi_0    pypi
[conda] mkl_fft                   1.3.1           py310hd6ae3a3_0  
[conda] mkl_random                1.2.2           py310h00e6091_0  
[conda] numpy                     1.23.5                   pypi_0    pypi
[conda] numpy-base                1.23.5          py310h8e6c178_0  
[conda] pytorch                   2.0.1           py3.10_cuda11.8_cudnn8.7.0_0    pytorch
[conda] pytorch-cuda              11.8                 h7e8668a_5    pytorch
[conda] pytorch-mutex             1.0                        cuda    pytorch
[conda] torch                     2.0.1                    pypi_0    pypi
[conda] torchaudio                2.0.2                    pypi_0    pypi
[conda] torchtriton               2.0.0                     py310    pytorch
[conda] torchview                 0.2.6                    pypi_0    pypi
[conda] torchvision               0.15.2                   pypi_0    pypi
[conda] triton                    2.0.0                    pypi_0    pypi