Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -3,6 +3,7 @@ import pandas as pd
|
|
3 |
import plotly.express as px
|
4 |
import nltk
|
5 |
|
|
|
6 |
nltk.download('punkt', force=True)
|
7 |
|
8 |
def count_tokens(text):
|
@@ -78,7 +79,7 @@ def main():
|
|
78 |
st.title("Lemma Frequency Visualization")
|
79 |
|
80 |
# Sidebar section
|
81 |
-
st.sidebar.image("imgs/DiGi_Thrace logo-tall.jpg", use_column_width=True
|
82 |
st.sidebar.markdown("""
|
83 |
### The Dataset:
|
84 |
The dataset is a curated collection of information on ancient geographical locations, rivers, tribes, and cultural aspects as documented by Pliny the Elder in *Naturalis Historia*. It includes lemmas (base forms of words), contextual information, and references to specific books and chapters from Pliny's work.
|
|
|
3 |
import plotly.express as px
|
4 |
import nltk
|
5 |
|
6 |
+
# Download punkt tokenizer forcefully to avoid LookupError
|
7 |
nltk.download('punkt', force=True)
|
8 |
|
9 |
def count_tokens(text):
|
|
|
79 |
st.title("Lemma Frequency Visualization")
|
80 |
|
81 |
# Sidebar section
|
82 |
+
st.sidebar.image("imgs/DiGi_Thrace logo-tall.jpg", use_column_width=True)
|
83 |
st.sidebar.markdown("""
|
84 |
### The Dataset:
|
85 |
The dataset is a curated collection of information on ancient geographical locations, rivers, tribes, and cultural aspects as documented by Pliny the Elder in *Naturalis Historia*. It includes lemmas (base forms of words), contextual information, and references to specific books and chapters from Pliny's work.
|