meg-huggingface commited on
Commit
e0ada71
1 Parent(s): 9af1e27

Fixing some minor breaks

Browse files
app.py CHANGED
@@ -117,7 +117,10 @@ def load_or_prepare(ds_args, show_embeddings, use_cache=False):
117
  logs.warning("Loading Embeddings")
118
  dstats.load_or_prepare_embeddings()
119
  logs.warning("Loading nPMI")
120
- dstats.load_or_prepare_npmi()
 
 
 
121
  logs.warning("Loading Zipf")
122
  dstats.load_or_prepare_zipf()
123
  return dstats
 
117
  logs.warning("Loading Embeddings")
118
  dstats.load_or_prepare_embeddings()
119
  logs.warning("Loading nPMI")
120
+ try:
121
+ dstats.load_or_prepare_npmi()
122
+ except:
123
+ logs.warning("Missing a cache for npmi")
124
  logs.warning("Loading Zipf")
125
  dstats.load_or_prepare_zipf()
126
  return dstats
data_measurements/dataset_statistics.py CHANGED
@@ -498,7 +498,7 @@ class DatasetStatisticsCacheClass:
498
  if not self.live:
499
  if self.tokenized_df is None:
500
  logs.warning("Tokenized dataset not yet loaded; doing so.")
501
- self.load_or_prepare_dataset()
502
  if self.vocab_counts_df is None:
503
  logs.warning("Vocab not yet loaded; doing so.")
504
  self.load_or_prepare_vocab()
@@ -544,8 +544,8 @@ class DatasetStatisticsCacheClass:
544
  """
545
  logs.info("Doing text dset.")
546
  self.load_or_prepare_text_dset(save)
547
- logs.info("Doing tokenized dataframe")
548
- self.load_or_prepare_tokenized_df(save)
549
  logs.info("Doing dataset peek")
550
  self.load_or_prepare_dset_peek(save)
551
 
 
498
  if not self.live:
499
  if self.tokenized_df is None:
500
  logs.warning("Tokenized dataset not yet loaded; doing so.")
501
+ self.load_or_prepare_tokenized_df()
502
  if self.vocab_counts_df is None:
503
  logs.warning("Vocab not yet loaded; doing so.")
504
  self.load_or_prepare_vocab()
 
544
  """
545
  logs.info("Doing text dset.")
546
  self.load_or_prepare_text_dset(save)
547
+ #logs.info("Doing tokenized dataframe")
548
+ #self.load_or_prepare_tokenized_df(save)
549
  logs.info("Doing dataset peek")
550
  self.load_or_prepare_dset_peek(save)
551
 
data_measurements/streamlit_utils.py CHANGED
@@ -20,7 +20,7 @@ import streamlit as st
20
  from st_aggrid import AgGrid, GridOptionsBuilder
21
 
22
  from .dataset_utils import HF_DESC_FIELD, HF_FEATURE_FIELD, HF_LABEL_FIELD
23
-
24
 
25
  def sidebar_header():
26
  st.sidebar.markdown(
 
20
  from st_aggrid import AgGrid, GridOptionsBuilder
21
 
22
  from .dataset_utils import HF_DESC_FIELD, HF_FEATURE_FIELD, HF_LABEL_FIELD
23
+ st.set_option('deprecation.showPyplotGlobalUse', False)
24
 
25
  def sidebar_header():
26
  st.sidebar.markdown(