Spaces:
Runtime error
Runtime error
import numpy as np | |
import gradio as gr | |
from gradio.mix import Series | |
import os | |
os.environ['CUDA_LAUNCH_BLOCKING'] = '1' # added after repeated runtime erros (seems with whisper) | |
description = "This space mixes the large-multilingual [emotion classification model of DReAMy](https://github.com/lorenzoscottb/DReAMy) with the whisper model from OpenAI, to directly classify recording according to the Hall and Van de Castle framework, with respect to emotions." | |
title = "DReAM v. II" | |
whisper = gr.Interface.load("models/openai/whisper-base") | |
interface_model_L = gr.Interface.load("models/DReAMy-lib/xlm-roberta-large-DreamBank-emotion-presence") | |
Series( | |
whisper, | |
interface_model_L, | |
description = description, | |
title = title, | |
inputs = gr.Audio(source="microphone"), | |
).launch() | |