Skip to content

Instantly share code, notes, and snippets.

@kusal1990
Created June 24, 2022 08:46
Show Gist options
  • Save kusal1990/86ff50bf247e1d52e7e5ffb96537b60b to your computer and use it in GitHub Desktop.
Save kusal1990/86ff50bf247e1d52e7e5ffb96537b60b to your computer and use it in GitHub Desktop.
challenge_train_preds = []
challenge_dev_preds = []
challenge_test_preds = []
for i in range(len(df_challenge_train)):
if '(1)' in df_challenge_train['only_answers'].iloc[i]:
challenge_train_preds.append(random.choice(num_list))
else:
if '(E)' in df_challenge_train['only_answers'].iloc[i]:
challenge_train_preds.append(random.choice(char_list_2))
else:
challenge_train_preds.append(random.choice(char_list_1))
for i in range(len(df_challenge_dev)):
if '(1)' in df_challenge_dev['only_answers'].iloc[i]:
challenge_dev_preds.append(random.choice(num_list))
else:
if '(E)' in df_challenge_dev['only_answers'].iloc[i]:
challenge_dev_preds.append(random.choice(char_list_2))
else:
challenge_dev_preds.append(random.choice(char_list_1))
for i in range(len(df_challenge_test)):
if '(1)' in df_challenge_test['only_answers'].iloc[i]:
challenge_test_preds.append(random.choice(num_list))
else:
if '(E)' in df_challenge_test['only_answers'].iloc[i]:
challenge_test_preds.append(random.choice(char_list_2))
else:
challenge_test_preds.append(random.choice(char_list_1))
@kusal1990
Copy link
Author

ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment