Spaces:
Runtime error
Runtime error
Changed title in app.py
Browse files
app.py
CHANGED
@@ -60,7 +60,6 @@ def inference(sentence):
|
|
60 |
certainy, highest_value = torch.max(predictions, dim=-1, keepdim=False, out=None)
|
61 |
highest_value_int = highest_value.item()
|
62 |
language = language_dict[highest_value_int]
|
63 |
-
#return ("This sentence is in " + language + ". Certainy: " + str(certainy.item()))
|
64 |
return language
|
65 |
|
66 |
if __name__ == '__main__':
|
@@ -68,7 +67,7 @@ if __name__ == '__main__':
|
|
68 |
inputs=gr.inputs.Textbox(placeholder="Enter text here", label="Text content", lines=5),
|
69 |
outputs=gr.outputs.Label(num_top_classes=6, label="Language of this text is "),
|
70 |
verbose=True,
|
71 |
-
title="Language
|
72 |
description="",
|
73 |
theme="grass")
|
74 |
interFace.launch()
|
|
|
60 |
certainy, highest_value = torch.max(predictions, dim=-1, keepdim=False, out=None)
|
61 |
highest_value_int = highest_value.item()
|
62 |
language = language_dict[highest_value_int]
|
|
|
63 |
return language
|
64 |
|
65 |
if __name__ == '__main__':
|
|
|
67 |
inputs=gr.inputs.Textbox(placeholder="Enter text here", label="Text content", lines=5),
|
68 |
outputs=gr.outputs.Label(num_top_classes=6, label="Language of this text is "),
|
69 |
verbose=True,
|
70 |
+
title="Language Detector",
|
71 |
description="",
|
72 |
theme="grass")
|
73 |
interFace.launch()
|