jarajpu commited on
Commit
3b2442f
·
1 Parent(s): 37781d2

enhanced leaderboard

Browse files
Files changed (1) hide show
  1. app.py +2 -5
app.py CHANGED
@@ -286,12 +286,9 @@ def display_leaderboard():
286
  try:
287
  # Load the 'leaders' configuration or split from your dataset
288
  dataset = load_dataset("Jay-Rajput/DIS_IPL_Leads", split='train')
289
- # Convert the dataset to a pandas DataFrame
290
- df_users = pd.DataFrame(dataset)
291
-
292
- # Transform the DataFrame to have 'user_name' and 'points' columns
293
  users_data = []
294
- for user, points_dict in df_users.items():
295
  points = points_dict.get("0", 0)
296
  users_data.append({'User': user, 'Points': points})
297
 
 
286
  try:
287
  # Load the 'leaders' configuration or split from your dataset
288
  dataset = load_dataset("Jay-Rajput/DIS_IPL_Leads", split='train')
289
+
 
 
 
290
  users_data = []
291
+ for user, points_dict in dataset.items():
292
  points = points_dict.get("0", 0)
293
  users_data.append({'User': user, 'Points': points})
294