devingulliver commited on
Commit
363a6cb
1 Parent(s): 0ef9934

Fix lingering issues from CheckboxGroup refactor

Browse files
Files changed (1) hide show
  1. app.py +4 -10
app.py CHANGED
@@ -9,16 +9,10 @@ webhook_url = os.environ.get("WEBHOOK_URL")
9
 
10
  def filter_table(name, type, arch, license):
11
  tmp = data
12
-
13
- if name:
14
- tmp = tmp[tmp["Name"].str.contains(name)]
15
- if type:
16
- tmp = tmp[tmp["Type"].isin(type)]
17
- if arch:
18
- tmp = tmp[tmp["Architecture"].isin(arch)]
19
- if license:
20
- tmp = tmp[tmp["License"].isin(license)]
21
-
22
  tmp["Name"] = tmp["Name"].apply(lambda x: f'<a target="_blank" href="https://huggingface.co/{x}" style="color: var(--link-text-color); text-decoration: underline;text-decoration-style: dotted;">{x}</a>')
23
  return tmp
24
 
 
9
 
10
  def filter_table(name, type, arch, license):
11
  tmp = data
12
+ tmp = tmp[tmp["Name"].str.contains(name)]
13
+ tmp = tmp[tmp["Type"].isin(type)]
14
+ tmp = tmp[tmp["Architecture"].isin(arch)]
15
+ tmp = tmp[tmp["License"].isin(license)]
 
 
 
 
 
 
16
  tmp["Name"] = tmp["Name"].apply(lambda x: f'<a target="_blank" href="https://huggingface.co/{x}" style="color: var(--link-text-color); text-decoration: underline;text-decoration-style: dotted;">{x}</a>')
17
  return tmp
18