Repository: gradio-app/gradio

Issue:
TypeError in TTS demo
### Describe the bug

Looking to demo a text-to-speech model using the [fastspeech2 checkpoint](https://huggingface.co/facebook/fastspeech2-en-ljspeech) from the HF hub as follows:
```python
import gradio as gr

gr.Interface.load("huggingface/facebook/fastspeech2-en-ljspeech").launch();
```
This yields the following demo: https://45412.gradio.app/
However, when I try and run the demo with any sort of input I just get `ERROR`. The demo should work as it does on the fastspeech2 model card: https://huggingface.co/facebook/fastspeech2-en-ljspeech

cc @AK391 

### Is there an existing issue for this?

- [X] I have searched the existing issues

### Reproduction

```python
import gradio as gr

gr.Interface.load("huggingface/facebook/fastspeech2-en-ljspeech").launch(debug=True);
```

### Screenshot

_No response_

### Logs

```shell
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/dist-packages/gradio/routes.py", line 256, in run_predict
    fn_index, raw_input, username, session_state
  File "/usr/local/lib/python3.7/dist-packages/gradio/blocks.py", line 546, in process_api
    predictions, duration = await self.call_function(fn_index, processed_input)
  File "/usr/local/lib/python3.7/dist-packages/gradio/blocks.py", line 462, in call_function
    block_fn.fn, *processed_input, limiter=self.limiter
  File "/usr/local/lib/python3.7/dist-packages/anyio/to_thread.py", line 32, in run_sync
    func, *args, cancellable=cancellable, limiter=limiter
  File "/usr/local/lib/python3.7/dist-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
    return await future
  File "/usr/local/lib/python3.7/dist-packages/anyio/_backends/_asyncio.py", line 867, in run
    result = context.run(func, *args)
  File "/usr/local/lib/python3.7/dist-packages/gradio/interface.py", line 509, in <lambda>
    if len(self.output_components) == 1
  File "/usr/local/lib/python3.7/dist-packages/gradio/interface.py", line 725, in run_prediction
    pred
  File "/usr/local/lib/python3.7/dist-packages/gradio/components.py", line 2103, in deserialize
    file = processing_utils.decode_base64_to_file(x["data"])
TypeError: string indices must be integers
```


### System Info

```shell
Gradio version: 3.0.20
System: G-colab (fresh install)
```


### Severity

blocking all usage of gradio


Discussion:

Resolving patch:
diff --git a/gradio/components.py b/gradio/components.py
--- a/gradio/components.py
+++ b/gradio/components.py
@@ -2119,7 +2119,7 @@ def postprocess(self, y):
         return processing_utils.encode_url_or_file_to_base64(y)
 
     def deserialize(self, x):
-        file = processing_utils.decode_base64_to_file(x["data"])
+        file = processing_utils.decode_base64_to_file(x)
         return file.name
 
     def stream(


Test patch:
diff --git a/test/test_components.py b/test/test_components.py
--- a/test/test_components.py
+++ b/test/test_components.py
@@ -843,7 +843,9 @@ def test_component_functions(self):
             },
         )
         self.assertTrue(
-            audio_output.deserialize(deepcopy(media_data.BASE64_AUDIO)).endswith(".wav")
+            audio_output.deserialize(
+                deepcopy(media_data.BASE64_AUDIO)["data"]
+            ).endswith(".wav")
         )
         with tempfile.TemporaryDirectory() as tmpdirname:
             to_save = audio_output.save_flagged(