Spaces:
Sleeping
Sleeping
osanseviero
commited on
Commit
•
613ab12
1
Parent(s):
1581d20
Launch for real
Browse files
models.py
CHANGED
@@ -151,11 +151,12 @@ def main():
|
|
151 |
langs = models_with_langs["languages"].explode()
|
152 |
langs = langs[langs != {}]
|
153 |
|
154 |
-
|
|
|
155 |
if filter == 1:
|
156 |
-
d =
|
157 |
elif filter == 2:
|
158 |
-
d =
|
159 |
|
160 |
# Just keep top 25 to avoid vertical scroll
|
161 |
d = d.iloc[:25]
|
@@ -166,14 +167,10 @@ def main():
|
|
166 |
))
|
167 |
|
168 |
st.subheader("Raw Data")
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
st.dataframe(l)
|
174 |
-
with col2:
|
175 |
-
d = langs.value_counts().rename_axis("language").to_frame('counts').reset_index()
|
176 |
-
st.dataframe(d)
|
177 |
|
178 |
|
179 |
|
|
|
151 |
langs = models_with_langs["languages"].explode()
|
152 |
langs = langs[langs != {}]
|
153 |
|
154 |
+
orig_d = langs.value_counts().rename_axis("language").to_frame('counts').reset_index()
|
155 |
+
d = orig_d
|
156 |
if filter == 1:
|
157 |
+
d = orig_d.iloc[1:]
|
158 |
elif filter == 2:
|
159 |
+
d = orig_d.iloc[10:]
|
160 |
|
161 |
# Just keep top 25 to avoid vertical scroll
|
162 |
d = d.iloc[:25]
|
|
|
167 |
))
|
168 |
|
169 |
st.subheader("Raw Data")
|
170 |
+
l = df1.rename_axis("lang_count").reset_index().rename(columns={"language_count": "repos_count"})
|
171 |
+
st.dataframe(l)
|
172 |
+
d = orig_d.astype(str)
|
173 |
+
st.dataframe(d)
|
|
|
|
|
|
|
|
|
174 |
|
175 |
|
176 |
|