kernel_id
stringclasses
4 values
code
stringlengths
1
1.59k
output
stringlengths
0
70.5M
execution_time
float64
0
60
memory_bytes
int64
50.7M
10.7B
runtime_variables
dict
hash_index
stringlengths
32
32
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0,inplace=True) test_features.fillna(0,inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21)
0.194007
132,894,720
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
201c0cafbfc6160333215ff621876c7f
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features
Out[1]: filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns] filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns]
0.033076
134,991,872
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
67706e33ce5deb9e7987dcfbacf9a72c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features type(train_feature)
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-a115130d9478>:3  1 train_features ----> 3 type(train_feature) NameError: name 'train_feature' is not defined Error: name 'train_feature' is not defined
0.103024
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d62e871850f75eebf021361f6d6989e3
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features type(train_features)
Out[1]: pandas.core.frame.DataFrame <class 'pandas.core.frame.DataFrame'>
0.004909
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
141b4a2c4e601f749a64c4ee1063ed06
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features
Out[1]: filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns] filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns]
0.032081
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
1c987ec71827805977bbfbe6534ce6e7
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
!pip install sklearn !pip install lightgbm as lbg
Collecting sklearn Using cached sklearn-0.0.post12.tar.gz (2.6 kB) Preparing metadata (setup.py) ... [?25l- error error: subprocess-exited-with-error × python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [15 lines of output]   The 'sklearn' PyPI package is deprecated, use 'scikit-learn'   rather than 'sklearn' for pip commands.     Here is how to fix this error in the main use cases:   - use 'pip install scikit-learn' rather than 'pip install sklearn'   - replace 'sklearn' by 'scikit-learn' in your pip requirements files   (requirements.txt, setup.py, setup.cfg, Pipfile, etc ...)   - if the 'sklearn' package is used by one of your dependencies,   it would be great if you take some time to track which package uses   'sklearn' instead of 'scikit-learn' and report it to their issue tracker   - as a last resort, set the environment variable   SKLEARN_ALLOW_DEPRECATED_SKLEARN_PACKAGE_INSTALL=True to avoid this error     More information is available at   https://github.com/scikit-learn/sklearn-pypi-package   [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed × Encountered error while generating package metadata. ╰─> See above for output. note: This is an issue with the package mentioned above, not pip. hint: See above for details. [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip [?25hRequirement already satisfied: lightgbm in /usr/local/lib/python3.9/site-packages (4.5.0) ERROR: Could not find a version that satisfies the requirement as (from versions: none) ERROR: No matching distribution found for as  [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip
1.124286
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
3e01ee2a6b103aefe548045db047bf67
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object')
0.004836
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
8d213e547d93f43c02dfdbfb7d02f981
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object')
0.003957
141,406,208
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": null, "target_drop": null, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
85e05b1bc24514afa12ce1eb67d5c13f
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
target_drop = ["primary_label", "load_data", "helper_functions", "data_preprocessing", "data_exploration", "modelling", "prediction", "evaluation", "result_visualization", "save_results", "comment_only"] target = train_features["primary_label"] train_features.drop(columns=target, inplace=True)
0.005346
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
391dd78a289c5e851457f2774a964c17
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.drop(columns=["filename"])
Out[1]: cell_type ... primary_label 0 code ... helper_functions 1 code ... load_data 2 code ... data_exploration 3 code ... data_exploration 4 code ... data_preprocessing ... ... ... ... 5828 code ... evaluation 5829 code ... modelling 5830 code ... data_preprocessing 5831 code ... modelling 5832 code ... evaluation [5833 rows x 21 columns] cell_type ... primary_label 0 code ... helper_functions 1 code ... load_data 2 code ... data_exploration 3 code ... data_exploration 4 code ... data_preprocessing ... ... ... ... 5828 code ... evaluation 5829 code ... modelling 5830 code ... data_preprocessing 5831 code ... modelling 5832 code ... evaluation [5833 rows x 21 columns]
0.026532
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9d75d48b7ecfe4a0ee4f1bc57bf4f1d2
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-e597d21fc49d>:1 ----> 1 clf = lgb.LGBMClassifier() NameError: name 'lgb' is not defined Error: name 'lgb' is not defined
0.01199
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
592b6cc09515ff26c5ca278ae654dc28
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
!pip install sklearn !pip install lightgbm as lgb
Collecting sklearn Using cached sklearn-0.0.post12.tar.gz (2.6 kB) Preparing metadata (setup.py) ... [?25l- error error: subprocess-exited-with-error × python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [15 lines of output]   The 'sklearn' PyPI package is deprecated, use 'scikit-learn'   rather than 'sklearn' for pip commands.     Here is how to fix this error in the main use cases:   - use 'pip install scikit-learn' rather than 'pip install sklearn'   - replace 'sklearn' by 'scikit-learn' in your pip requirements files   (requirements.txt, setup.py, setup.cfg, Pipfile, etc ...)   - if the 'sklearn' package is used by one of your dependencies,   it would be great if you take some time to track which package uses   'sklearn' instead of 'scikit-learn' and report it to their issue tracker   - as a last resort, set the environment variable   SKLEARN_ALLOW_DEPRECATED_SKLEARN_PACKAGE_INSTALL=True to avoid this error     More information is available at   https://github.com/scikit-learn/sklearn-pypi-package   [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed × Encountered error while generating package metadata. ╰─> See above for output. note: This is an issue with the package mentioned above, not pip. hint: See above for details. [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip [?25hRequirement already satisfied: lightgbm in /usr/local/lib/python3.9/site-packages (4.5.0) ERROR: Could not find a version that satisfies the requirement as (from versions: none) ERROR: No matching distribution found for as  [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip
1.064995
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
eb1755538fd9b2396a224c2c901ac790
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
!pip install sklearn !pip install lightgbm
Collecting sklearn Using cached sklearn-0.0.post12.tar.gz (2.6 kB) Preparing metadata (setup.py) ... [?25l- error error: subprocess-exited-with-error × python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [15 lines of output]   The 'sklearn' PyPI package is deprecated, use 'scikit-learn'   rather than 'sklearn' for pip commands.     Here is how to fix this error in the main use cases:   - use 'pip install scikit-learn' rather than 'pip install sklearn'   - replace 'sklearn' by 'scikit-learn' in your pip requirements files   (requirements.txt, setup.py, setup.cfg, Pipfile, etc ...)   - if the 'sklearn' package is used by one of your dependencies,   it would be great if you take some time to track which package uses   'sklearn' instead of 'scikit-learn' and report it to their issue tracker   - as a last resort, set the environment variable   SKLEARN_ALLOW_DEPRECATED_SKLEARN_PACKAGE_INSTALL=True to avoid this error     More information is available at   https://github.com/scikit-learn/sklearn-pypi-package   [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed × Encountered error while generating package metadata. ╰─> See above for output. note: This is an issue with the package mentioned above, not pip. hint: See above for details. [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip [?25hRequirement already satisfied: lightgbm in /usr/local/lib/python3.9/site-packages (4.5.0) Requirement already satisfied: numpy>=1.17.0 in /usr/local/lib/python3.9/site-packages (from lightgbm) (1.26.4) Requirement already satisfied: scipy in /usr/local/lib/python3.9/site-packages (from lightgbm) (1.13.1) WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv  [notice] A new release of pip is available: 23.0.1 -> 25.0 [notice] To update, run: pip install --upgrade pip
1.267826
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
401633d321a74dca7f418c2f673aacf5
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-e597d21fc49d>:1 ----> 1 clf = lgb.LGBMClassifier() NameError: name 'lgb' is not defined Error: name 'lgb' is not defined
0.013636
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
f03fe1cde183b0520738397da8a3c2dd
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-e597d21fc49d>:1 ----> 1 clf = lgb.LGBMClassifier() NameError: name 'lgb' is not defined Error: name 'lgb' is not defined
0.010982
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
eeae56585cdd8d4f9e25581c8103ba2c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label'], dtype='object')
0.005477
142,454,784
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
65daf2a2386f3698db6aaa763bcfd209
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf.train(train[['cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']])
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-a2c2fc20951a>:1 ----> 1 clf.train(train[['cell_type', 'cell_number', 'execution_count',  2 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]) NameError: name 'clf' is not defined Error: name 'clf' is not defined
0.011059
142,848,000
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d259db0840ae11502cf84d8b623daf43
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-e597d21fc49d>:1 ----> 1 clf = lgb.LGBMClassifier() NameError: name 'lgb' is not defined Error: name 'lgb' is not defined
0.010958
142,848,000
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 4990589, "type": "DataFrame", "value": " filename ... primary_label\n0 nb_54880.ipynb ... helper_functions\n1 nb_54880.ipynb ... load_data\n2 nb_54880.ipynb ... data_exploration\n3 nb_54880.ipynb ... data_exploration\n4 nb_54880.ipynb ... data_preprocessing\n... ... ... ...\n5828 nb_95821.ipynb ... evaluation\n5829 nb_95821.ipynb ... modelling\n5830 nb_95821.ipynb ... data_preprocessing\n5831 nb_95821.ipynb ... modelling\n5832 nb_95821.ipynb ... evaluation\n\n[5833 rows x 22 columns]" }, "train_test_split": null, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
96c552c3b7573959e01aec29fbe42454
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21)
0.290246
235,937,792
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": null, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a5ad4ad81a2dd9aa089b97b772ff2a89
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
0.005449
235,937,792
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
bb6f70f84b148b2a2d36ae2820b297ff
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf.train(train[['cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']])
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) File <ipython-input-1-a2c2fc20951a>:1 ----> 1 clf.train(train[['cell_type', 'cell_number', 'execution_count',  2 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]) AttributeError: 'LGBMClassifier' object has no attribute 'train' Error: 'LGBMClassifier' object has no attribute 'train'
0.026057
236,068,864
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
7c0d7d86287768aab34d6876fd93d3c9
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf.fit(train_features[['cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']], target)
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-36d4750cad1d>:1 ----> 1 clf.fit(train_features[['cell_type', 'cell_number', 'execution_count',  2  'linesofcomment', 'linesofcode', 'variable_count', 'function_count']], target) File /usr/local/lib/python3.9/site-packages/lightgbm/sklearn.py:1284, in LGBMClassifier.fit(self, X, y, sample_weight, init_score, eval_set, eval_names, eval_sample_weight, eval_class_weight, eval_init_score, eval_metric, feature_name, categorical_feature, callbacks, init_model)  1281 else:  1282 valid_sets.append((valid_x, self._le.transform(valid_y))) -> 1284 super().fit(  1285  X,  1286  _y,  1287  sample_weight=sample_weight,  1288  init_score=init_score,  1289  eval_set=valid_sets,  1290  eval_names=eval_names,  1291  eval_sample_weight=eval_sample_weight,  1292  eval_class_weight=eval_class_weight,  1293  eval_init_score=eval_init_score,  1294  eval_metric=eval_metric,  1295  feature_name=feature_name,  1296  categorical_feature=categorical_feature,  1297  callbacks=callbacks,  1298  init_model=init_model,  1299 )  1300 return self File /usr/local/lib/python3.9/site-packages/lightgbm/sklearn.py:955, in LGBMModel.fit(self, X, y, sample_weight, init_score, group, eval_set, eval_names, eval_sample_weight, eval_class_weight, eval_init_score, eval_group, eval_metric, feature_name, categorical_feature, callbacks, init_model)  952 evals_result: _EvalResultDict = {}  953 callbacks.append(record_evaluation(evals_result)) --> 955 self._Booster = train(  956  params=params,  957  train_set=train_set,  958  num_boost_round=self.n_estimators,  959  valid_sets=valid_sets,  960  valid_names=eval_names,  961  feval=eval_metrics_callable, # type: ignore[arg-type]  962  init_model=init_model,  963  callbacks=callbacks,  964 )  966 self._evals_result = evals_result  967 self._best_iteration = self._Booster.best_iteration File /usr/local/lib/python3.9/site-packages/lightgbm/engine.py:282, in train(params, train_set, num_boost_round, valid_sets, valid_names, feval, init_model, feature_name, categorical_feature, keep_training_booster, callbacks)  280 # construct booster  281 try: --> 282 booster = Booster(params=params, train_set=train_set)  283 if is_valid_contain_train:  284 booster.set_train_data_name(train_data_name) File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:3637, in Booster.__init__(self, params, train_set, model_file, model_str)  3630 self.set_network(  3631 machines=machines,  3632 local_listen_port=params["local_listen_port"],  3633 listen_time_out=params.get("time_out", 120),  3634 num_machines=params["num_machines"],  3635 )  3636 # construct booster object -> 3637 train_set.construct()  3638 # copy the parameters from train_set  3639 params.update(train_set.get_params()) File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:2576, in Dataset.construct(self)  2571 self._set_init_score_by_predictor(  2572 predictor=self._predictor, data=self.data, used_indices=used_indices  2573 )  2574 else:  2575 # create train -> 2576 self._lazy_init(  2577  data=self.data,  2578  label=self.label,  2579  reference=None,  2580  weight=self.weight,  2581  group=self.group,  2582  init_score=self.init_score,  2583  predictor=self._predictor,  2584  feature_name=self.feature_name,  2585  categorical_feature=self.categorical_feature,  2586  params=self.params,  2587  position=self.position,  2588  )  2589 if self.free_raw_data:  2590 self.data = None File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:2106, in Dataset._lazy_init(self, data, label, reference, weight, group, init_score, predictor, feature_name, categorical_feature, params, position)  2104 categorical_feature = reference.categorical_feature  2105 if isinstance(data, pd_DataFrame): -> 2106 data, feature_name, categorical_feature, self.pandas_categorical = _data_from_pandas(  2107  data=data,  2108  feature_name=feature_name,  2109  categorical_feature=categorical_feature,  2110  pandas_categorical=self.pandas_categorical,  2111  )  2113 # process for args  2114 params = {} if params is None else params File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:848, in _data_from_pandas(data, feature_name, categorical_feature, pandas_categorical)  844 df_dtypes.append(np.float32)  845 target_dtype = np.result_type(*df_dtypes)  847 return ( --> 848 _pandas_to_numpy(data, target_dtype=target_dtype),  849 feature_name,  850 categorical_feature,  851 pandas_categorical,  852 ) File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:794, in _pandas_to_numpy(data, target_dtype)  790 def _pandas_to_numpy(  791 data: pd_DataFrame,  792 target_dtype: "np.typing.DTypeLike",  793 ) -> np.ndarray: --> 794 _check_for_bad_pandas_dtypes(data.dtypes)  795 try:  796 # most common case (no nullable dtypes)  797 return data.to_numpy(dtype=target_dtype, copy=False) File /usr/local/lib/python3.9/site-packages/lightgbm/basic.py:784, in _check_for_bad_pandas_dtypes(pandas_dtypes_series)  778 bad_pandas_dtypes = [  779 f"{column_name}: {pandas_dtype}"  780 for column_name, pandas_dtype in pandas_dtypes_series.items()  781 if not _is_allowed_numpy_dtype(pandas_dtype.type)  782 ]  783 if bad_pandas_dtypes: --> 784 raise ValueError(  785 'pandas dtypes must be int, float or bool.\n'  786 f'Fields with bad pandas dtypes: {", ".join(bad_pandas_dtypes)}'  787 ) ValueError: pandas dtypes must be int, float or bool. Fields with bad pandas dtypes: cell_type: object Error: pandas dtypes must be int, float or bool. Fields with bad pandas dtypes: cell_type: object
0.39015
247,578,624
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
afc00ece715a191cb4585fc2bf672fdf
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf.fit(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']], target)
Out[1]: LGBMClassifier() LGBMClassifier()
0.845052
256,839,680
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
8fe1d64afbd59ac7a745b59d5a3c7e77
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf.fit(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']], target)
Out[1]: LGBMClassifier() LGBMClassifier()
1.050409
265,506,816
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9e1697bbf301a9c17ec6c6ce6d99b381
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]) target)
 File <ipython-input-1-c806046091db>:2  'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]) target)  ^ SyntaxError: invalid syntax Error: None
0.003835
265,506,816
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d0392ef2c011e9e34ea0dedecde6b050
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]), target)
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-6ec66d383ec0>:1 ----> 1 accuracy_score(clf.predict(train_features[['cell_number', 'execution_count',  2 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]), target) NameError: name 'accuracy_score' is not defined Error: name 'accuracy_score' is not defined
0.011244
265,637,888
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": null, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
57a722591a4a5c2dce5ece54bc5965bc
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21)
0.077509
282,116,096
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
c151186e6981034d84257ed0086a8e5e
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]), target)
Out[1]: 0.797531287502143 0.797531287502143
0.040105
283,426,816
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
0ca43413ea161c1e3511db7a7f43840a
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(train_features[['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count']]), target)
Out[1]: 0.797531287502143 0.797531287502143
0.037235
283,426,816
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
22c34da5662945830f579b2ffb794851
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
clf = lgb.LGBMClassifier()
0.004447
283,426,816
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": null, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d88608dfc195a5c3c74f6ffe8391cf5e
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_columns = ['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error'] clf.fit(train_features[train_columns], target)
Out[1]: LGBMClassifier() LGBMClassifier()
1.402952
288,612,352
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9791f5f3890226ec9c47e1a648ac2db2
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(train_features[train_columns]), target)
Out[1]: 0.8400480027430138 0.8400480027430138
0.037897
288,743,424
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
92f9845971518f06100a04b0d119a180
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
target.value_counts()
Out[1]: primary_label data_exploration 1664 data_preprocessing 1396 modelling 922 helper_functions 467 load_data 434 result_visualization 292 evaluation 233 prediction 180 comment_only 135 save_results 110 Name: count, dtype: int64 primary_label data_exploration 1664 data_preprocessing 1396 modelling 922 helper_functions 467 load_data 434 result_visualization 292 evaluation 233 prediction 180 comment_only 135 save_results 110 Name: count, dtype: int64
0.005388
288,890,880
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a8ddef30b7247b3ed05e8c7d5d81ba69
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
target.value_counts(normalize=True)
Out[1]: primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64 primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64
0.006626
288,890,880
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
828f07fc32d8a3a2539ed586e31eebcf
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
target.value_counts(normalize=True)
Out[1]: primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64 primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64
0.006949
288,890,880
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9d15feeff411f64b54540e658e716b6e
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(test_features[train_columns]), test_features["primary_label"])
--------------------------------------------------------------------------- KeyError Traceback (most recent call last) File /usr/local/lib/python3.9/site-packages/pandas/core/indexes/base.py:3805, in Index.get_loc(self, key)  3804 try: -> 3805 return self._engine.get_loc(casted_key)  3806 except KeyError as err: File index.pyx:167, in pandas._libs.index.IndexEngine.get_loc() File index.pyx:196, in pandas._libs.index.IndexEngine.get_loc() File pandas/_libs/hashtable_class_helper.pxi:7081, in pandas._libs.hashtable.PyObjectHashTable.get_item() File pandas/_libs/hashtable_class_helper.pxi:7089, in pandas._libs.hashtable.PyObjectHashTable.get_item() KeyError: 'primary_label' The above exception was the direct cause of the following exception: KeyError Traceback (most recent call last) File <ipython-input-1-54ea9b48c1cc>:1 ----> 1 accuracy_score(clf.predict(test_features[train_columns]), test_features["primary_label"]) File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:4102, in DataFrame.__getitem__(self, key)  4100 if self.columns.nlevels > 1:  4101 return self._getitem_multilevel(key) -> 4102 indexer = self.columns.get_loc(key)  4103 if is_integer(indexer):  4104 indexer = [indexer] File /usr/local/lib/python3.9/site-packages/pandas/core/indexes/base.py:3812, in Index.get_loc(self, key)  3807 if isinstance(casted_key, slice) or (  3808 isinstance(casted_key, abc.Iterable)  3809 and any(isinstance(x, slice) for x in casted_key)  3810 ):  3811 raise InvalidIndexError(key) -> 3812 raise KeyError(key) from err  3813 except TypeError:  3814 # If we have a listlike key, _check_indexing_error will raise  3815 # InvalidIndexError. Otherwise we fall through and re-raise  3816 # the TypeError.  3817 self._check_indexing_error(key) KeyError: 'primary_label' Error: 'primary_label'
0.395222
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
e427c292517ee0760b4d3897207f6bf4
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns test_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info'], dtype='object')
0.00602
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
419868f4e2cfd5ebcb1492c87e48177b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns validation_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object')
0.005921
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9a424ea348b564df03afa869be4bd98d
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(validation_features[train_columns]), validation_features["primary_label"])
Out[1]: 0.5365853658536586 0.5365853658536586
0.018844
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
5e761cde4a9be16cd38f668aaf3c0bea
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(validation_features[train_columns]), validation_features["primary_label"])
Out[1]: 0.5365853658536586 0.5365853658536586
0.021231
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a41635c6659cbd9aec0fa8fe487d4cae
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(validation_features[train_columns]), validation_features["primary_label"])
Out[1]: 0.5365853658536586 0.5365853658536586
0.017821
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
93af7d980c64a0e6764f9ec85b9ab5e8
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(validation_features[train_columns]), validation_features["primary_label"])
Out[1]: 0.5365853658536586 0.5365853658536586
0.021425
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
06428dc58437cded19ee2568dacfd6f4
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
accuracy_score(clf.predict(validation_features[train_columns]), validation_features["primary_label"])
Out[1]: 0.5365853658536586 0.5365853658536586
0.018781
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a1396408444015dd3203a2e6b4be29d7
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
target.value_counts(normalize=True)
Out[1]: primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64 primary_label data_exploration 0.285273 data_preprocessing 0.239328 modelling 0.158066 helper_functions 0.080062 load_data 0.074404 result_visualization 0.050060 evaluation 0.039945 prediction 0.030859 comment_only 0.023144 save_results 0.018858 Name: proportion, dtype: float64
0.006623
308,031,488
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": null, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": null, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
e54559aabc969f4e5fdf692776d01b55
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# accuracy_score(, validation_features["primary_label"]) pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.021889
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
07b8b0f801d0860349972d209ca0a797
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# accuracy_score(, validation_features["primary_label"]) pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.022657
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
c33d6a6cf87f59c027a314f78e8bef08
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# accuracy_score(, validation_features["primary_label"]) pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.023017
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
ad5ae01f42a6b65c8c9a236ddb868548
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# accuracy_score(, validation_features["primary_label"]) pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.020862
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
14322add7f9545e00f0ed810e93a125b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# accuracy_score(, validation_features["primary_label"]) pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.02148
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
c687ff4a52d3dc195947059008d775d8
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.022594
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
ff535105a2176276389aaa0b6de09b4c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.02127
308,162,560
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
28b82541aa4ebe81e80f7546f7cd0e14
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.021063
308,293,632
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
422eb68cdd9e28352cb07eb67187c2a9
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.021595
308,424,704
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
1118462be9a83fd20b97f4a7628496e1
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.021122
308,424,704
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
fa06a2ca420cdf8fb5c22c62f4ae07ba
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.04944
308,424,704
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d0973457b5f801447efec0d0925a32d9
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average="weighted")
Out[1]: 0.5479133178319338 0.5479133178319338
0.020237
308,555,776
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
ab9d56904607096c37253bc3b93de7dc
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average=None)
Out[1]: array([0.97674419, 0.68326848, 0.53424658, 0.10869565, 0.68401487, 0.416 , 0.35075885, 0. , 0.2826087 , 0.04761905]) array([0.97674419, 0.68326848, 0.53424658, 0.10869565, 0.68401487, 0.416 , 0.35075885, 0. , 0.2826087 , 0.04761905])
0.019805
308,817,920
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
b032f7dbde804af9c66ab0bf0706696a
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score f1_score(pred, validation_features["primary_label"], average=None)
Out[1]: array([0.97674419, 0.68326848, 0.53424658, 0.10869565, 0.68401487, 0.416 , 0.35075885, 0. , 0.2826087 , 0.04761905]) array([0.97674419, 0.68326848, 0.53424658, 0.10869565, 0.68401487, 0.416 , 0.35075885, 0. , 0.2826087 , 0.04761905])
0.021076
308,817,920
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
28aca0392965acaa209de1fb1c7b9dd6
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
pred = clf.predict(validation_features[train_columns]) from sklearn.metrics import f1_score # f1_score(pred, validation_features["primary_label"], average=None) f1_score(pred, validation_features["primary_label"], average='weighted')
Out[1]: 0.5479133178319338 0.5479133178319338
0.020088
309,211,136
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": null, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": null, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": null, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
1e720e0f06fb3c077dd188385af86810
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# sklearn.linear_model.LogisticRegression from sklearn.feature_extraction.text import TfidfVectorizer vectorizer = TfidfVectorizer() corpus = "I want some pitsaa" X = vectorizer.fit_transform(corpus) # X = vectorizer.fit_transform(corpus) X
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-68374230477f>:6  4 vectorizer = TfidfVectorizer()  5 corpus = "I want some pitsaa" ----> 6 X = vectorizer.fit_transform(corpus)  7 # X = vectorizer.fit_transform(corpus)  8 X File /usr/local/lib/python3.9/site-packages/sklearn/feature_extraction/text.py:2104, in TfidfVectorizer.fit_transform(self, raw_documents, y)  2097 self._check_params()  2098 self._tfidf = TfidfTransformer(  2099 norm=self.norm,  2100 use_idf=self.use_idf,  2101 smooth_idf=self.smooth_idf,  2102 sublinear_tf=self.sublinear_tf,  2103 ) -> 2104 X = super().fit_transform(raw_documents)  2105 self._tfidf.fit(X)  2106 # X is already a transformed view of raw_documents so  2107 # we set copy to False File /usr/local/lib/python3.9/site-packages/sklearn/base.py:1389, in _fit_context.<locals>.decorator.<locals>.wrapper(estimator, *args, **kwargs)  1382 estimator._validate_params()  1384 with config_context(  1385 skip_parameter_validation=(  1386 prefer_skip_nested_validation or global_skip_validation  1387 )  1388 ): -> 1389 return fit_method(estimator, *args, **kwargs) File /usr/local/lib/python3.9/site-packages/sklearn/feature_extraction/text.py:1354, in CountVectorizer.fit_transform(self, raw_documents, y)  1350 # We intentionally don't call the transform method to make  1351 # fit_transform overridable without unwanted side effects in  1352 # TfidfVectorizer.  1353 if isinstance(raw_documents, str): -> 1354 raise ValueError(  1355 "Iterable over raw text documents expected, string object received."  1356 )  1358 self._validate_ngram_range()  1359 self._warn_for_unused_params() ValueError: Iterable over raw text documents expected, string object received. Error: Iterable over raw text documents expected, string object received.
0.0739
314,585,088
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": null, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 67, "type": "str", "value": "I want some pitsaa" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
32b825c6ab38bdac29d036938e2f5529
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# sklearn.linear_model.LogisticRegression from sklearn.feature_extraction.text import TfidfVectorizer vectorizer = TfidfVectorizer() corpus = ["I want some pitsa"] X = vectorizer.fit_transform(corpus) # X = vectorizer.fit_transform(corpus) X
Out[1]: <1x3 sparse matrix of type '<class 'numpy.float64'>' with 3 stored elements in Compressed Sparse Row format> <1x3 sparse matrix of type '<class 'numpy.float64'>' with 3 stored elements in Compressed Sparse Row format>
0.005047
314,982,400
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a6606593fd9d7898f65be7c8916de3ff
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# sklearn.linear_model.LogisticRegression from sklearn.feature_extraction.text import TfidfVectorizer vectorizer = TfidfVectorizer() corpus = ["I want some pitsa"] X = vectorizer.fit_transform(corpus) # X = vectorizer.fit_transform(corpus) X.to_array()
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) File <ipython-input-1-79dc4f2d01be>:8  6 X = vectorizer.fit_transform(corpus)  7 # X = vectorizer.fit_transform(corpus) ----> 8 X.to_array() AttributeError: 'csr_matrix' object has no attribute 'to_array' Error: 'csr_matrix' object has no attribute 'to_array'
0.012339
315,244,544
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
f10e4785878466027c9ca0b6ef879e4b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# sklearn.linear_model.LogisticRegression from sklearn.feature_extraction.text import TfidfVectorizer vectorizer = TfidfVectorizer() corpus = ["I want some pitsa"] X = vectorizer.fit_transform(corpus) # X = vectorizer.fit_transform(corpus) X.to_list()
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) File <ipython-input-1-b18237769b50>:8  6 X = vectorizer.fit_transform(corpus)  7 # X = vectorizer.fit_transform(corpus) ----> 8 X.to_list() AttributeError: 'csr_matrix' object has no attribute 'to_list' Error: 'csr_matrix' object has no attribute 'to_list'
0.011412
315,244,544
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
05b82bd3deacc9eecc3bc8cf330ed1c0
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# sklearn.linear_model.LogisticRegression from sklearn.feature_extraction.text import TfidfVectorizer vectorizer = TfidfVectorizer() corpus = ["I want some pitsa"] X = vectorizer.fit_transform(corpus) # X = vectorizer.fit_transform(corpus) X
Out[1]: <1x3 sparse matrix of type '<class 'numpy.float64'>' with 3 stored elements in Compressed Sparse Row format> <1x3 sparse matrix of type '<class 'numpy.float64'>' with 3 stored elements in Compressed Sparse Row format>
0.004158
315,375,616
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
6268f9932d5eced3665b564aa9ed71f4
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1]
Out[1]: ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters'] ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters']
0.003531
315,375,616
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
7e9dfec8ac1fa2840d0009c105759825
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1]
Out[1]: ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters'] ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters']
0.005863
315,375,616
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
6465c27241d2d441bb9330acd2ea3cf6
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1]
Out[1]: ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters'] ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters']
0.005256
315,375,616
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
34138f7c4c3397b46410f896bbaa5dc7
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.sample(20)
Out[1]: filename cell_type ... save_results comment_only 5134 nb_78623.ipynb code ... 0 0 5195 nb_8001.ipynb code ... 0 0 1370 nb_18303.ipynb code ... 0 0 2432 nb_33105.ipynb code ... 0 0 4182 nb_597.ipynb code ... 0 0 3312 nb_5274.ipynb code ... 0 0 3152 nb_50130.ipynb code ... 0 0 2293 nb_29702.ipynb code ... 0 0 4543 nb_66900.ipynb code ... 0 0 4526 nb_65930.ipynb code ... 0 0 3441 nb_55599.ipynb code ... 0 0 2375 nb_31109.ipynb code ... 0 0 1123 nb_14954.ipynb code ... 0 0 2316 nb_30808.ipynb code ... 0 0 514 nb_132144.ipynb code ... 0 0 2351 nb_31061.ipynb code ... 0 0 3901 nb_59012.ipynb code ... 0 0 5628 nb_88675.ipynb code ... 0 0 4527 nb_65930.ipynb code ... 0 0 3332 nb_54112.ipynb code ... 0 0 [20 rows x 32 columns] filename cell_type ... save_results comment_only 5134 nb_78623.ipynb code ... 0 0 5195 nb_8001.ipynb code ... 0 0 1370 nb_18303.ipynb code ... 0 0 2432 nb_33105.ipynb code ... 0 0 4182 nb_597.ipynb code ... 0 0 3312 nb_5274.ipynb code ... 0 0 3152 nb_50130.ipynb code ... 0 0 2293 nb_29702.ipynb code ... 0 0 4543 nb_66900.ipynb code ... 0 0 4526 nb_65930.ipynb code ... 0 0 3441 nb_55599.ipynb code ... 0 0 2375 nb_31109.ipynb code ... 0 0 1123 nb_14954.ipynb code ... 0 0 2316 nb_30808.ipynb code ... 0 0 514 nb_132144.ipynb code ... 0 0 2351 nb_31061.ipynb code ... 0 0 3901 nb_59012.ipynb code ... 0 0 5628 nb_88675.ipynb code ... 0 0 4527 nb_65930.ipynb code ... 0 0 3332 nb_54112.ipynb code ... 0 0 [20 rows x 32 columns]
0.039783
315,506,688
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
9e9fa424d5d0ab48bd8e092dc3d91d0c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.sample(20)[["code_line_before"]]
Out[1]: code_line_before 5390 [plt.show()] 2239 [SDG_Targets.head(1)] 2423 [inertia.append(kmeans.inertia_)] 3710 [from model_saver import load_model_w_weights] 2301 ["New Sample, Class Prediction: {}\n".forma... 407 [display(arr_to_img(val_out[sample_i, :, :, :3... 716 [%matplotlib inline] 2131 [sixth_data_frame] 4697 [valid_features, valid_labels = pickle.load(op... 5092 [dataset_training['Class'] = dataset_training.... 2774 [print (after_pca.n_components)] 4507 [np.random.seed(42)] 323 [import numpy as np] 4090 [s_award_name = s_won.str.split('(\d+ )').str[... 2921 [return (weights)] 5358 [fig = draw(g, font_size=8)] 4936 [)] 2813 [Calls.head()] 1248 [num_features = num_features.columns.values] 3348 [tests.test_con_pool(conv2d_maxpool)] code_line_before 5390 [plt.show()] 2239 [SDG_Targets.head(1)] 2423 [inertia.append(kmeans.inertia_)] 3710 [from model_saver import load_model_w_weights] 2301 ["New Sample, Class Prediction: {}\n".forma... 407 [display(arr_to_img(val_out[sample_i, :, :, :3... 716 [%matplotlib inline] 2131 [sixth_data_frame] 4697 [valid_features, valid_labels = pickle.load(op... 5092 [dataset_training['Class'] = dataset_training.... 2774 [print (after_pca.n_components)] 4507 [np.random.seed(42)] 323 [import numpy as np] 4090 [s_award_name = s_won.str.split('(\d+ )').str[... 2921 [return (weights)] 5358 [fig = draw(g, font_size=8)] 4936 [)] 2813 [Calls.head()] 1248 [num_features = num_features.columns.values] 3348 [tests.test_con_pool(conv2d_maxpool)]
0.011084
315,506,688
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
48834e65ba8f95258c628e42637043c1
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.sample(20)[["code_line_before"]]
Out[1]: code_line_before 4672 [train_df = train_df.drop('sub_area', 1)] 4591 [print(boston.target.shape)] 2195 [plt.plot(data3_diff)] 5383 [plt.show()] 5484 [pixel_coordinates = {"latitude":25.228928,"lo... 3102 [sentences = [[stem(word) for word in sentence... 1196 [train_step = tf.train.GradientDescentOptimize... 5541 [get_ipython().magic('matplotlib inline')] 5567 [print(prob)] 1592 [plt.imshow(img_d)] 1389 [wifi_data.head()] 5162 [('classifier', LinearSVC(C=100))])] 2034 0 4585 [boston.keys()] 3672 [print(aedesaegypti.size)] 5513 [del df_test, df_train] 373 [severityDf = pd.read_csv("{}/{}".format(path,... 5589 [tpot.export('tpot_iris_pipeline.py')] 777 [plt.show()] 229 [print("Within Set Sum of Squared Errors = " +... code_line_before 4672 [train_df = train_df.drop('sub_area', 1)] 4591 [print(boston.target.shape)] 2195 [plt.plot(data3_diff)] 5383 [plt.show()] 5484 [pixel_coordinates = {"latitude":25.228928,"lo... 3102 [sentences = [[stem(word) for word in sentence... 1196 [train_step = tf.train.GradientDescentOptimize... 5541 [get_ipython().magic('matplotlib inline')] 5567 [print(prob)] 1592 [plt.imshow(img_d)] 1389 [wifi_data.head()] 5162 [('classifier', LinearSVC(C=100))])] 2034 0 4585 [boston.keys()] 3672 [print(aedesaegypti.size)] 5513 [del df_test, df_train] 373 [severityDf = pd.read_csv("{}/{}".format(path,... 5589 [tpot.export('tpot_iris_pipeline.py')] 777 [plt.show()] 229 [print("Within Set Sum of Squared Errors = " +...
0.011213
315,506,688
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
82b965e7a86ad0be85b88e0838d9cbb8
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.sample(30)[["code_line_before"]]
Out[1]: code_line_before 4332 [x_train_reduced.shape, x_test_reduced.shape] 3170 [from treeinterpreter import treeinterpreter a... 3115 [model.most_similar("game")] 4624 [sklearn.metrics.mean_squared_error(bos.PRICE,... 270 [tests.test_generator(generator, tf)] 4310 [isolation(yemen_data)] 4255 0 3113 [model.wv.most_similar(positive=['men', 'gamer... 1724 [len(X_train_ridge)] 655 [sin(pi)] 5541 [get_ipython().magic('matplotlib inline')] 3188 [df_stations['traffic'] = df_stations.net_entr... 4834 [l_rnn.output_shape] 814 [return group] 5731 [idps_table] 3590 [plt.imshow(x0_train[5555], cmap="Wistia")] 166 [plt.show()] 1616 [inm] 3401 [topicDict[2][:5]] 5183 [pitchab.groupby('pitch_type').min()[['pfx_x',... 4726 [sat_m_t.areaname[91]] 5392 [plt.show()] 4654 [f.close()] 3013 0 231 [model_k3.transform(cluster_final_data).groupB... 766 0 4581 [pprint(grid_search.grid_scores_)] 4746 [new=pd.DataFrame({"gender":gender,"tjob":tjob... 114 [return ev] 922 [print(data[(data['RM']>=8)&(data['RM']<8.2)&(... code_line_before 4332 [x_train_reduced.shape, x_test_reduced.shape] 3170 [from treeinterpreter import treeinterpreter a... 3115 [model.most_similar("game")] 4624 [sklearn.metrics.mean_squared_error(bos.PRICE,... 270 [tests.test_generator(generator, tf)] 4310 [isolation(yemen_data)] 4255 0 3113 [model.wv.most_similar(positive=['men', 'gamer... 1724 [len(X_train_ridge)] 655 [sin(pi)] 5541 [get_ipython().magic('matplotlib inline')] 3188 [df_stations['traffic'] = df_stations.net_entr... 4834 [l_rnn.output_shape] 814 [return group] 5731 [idps_table] 3590 [plt.imshow(x0_train[5555], cmap="Wistia")] 166 [plt.show()] 1616 [inm] 3401 [topicDict[2][:5]] 5183 [pitchab.groupby('pitch_type').min()[['pfx_x',... 4726 [sat_m_t.areaname[91]] 5392 [plt.show()] 4654 [f.close()] 3013 0 231 [model_k3.transform(cluster_final_data).groupB... 766 0 4581 [pprint(grid_search.grid_scores_)] 4746 [new=pd.DataFrame({"gender":gender,"tjob":tjob... 114 [return ev] 922 [print(data[(data['RM']>=8)&(data['RM']<8.2)&(...
0.013448
315,506,688
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
0d2dc212bdba7375161db31bf4557a3c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.sample(30)[["text"]]
Out[1]: text 1553 [n_comps = 1 + np.argmax(vc > 0.95), data_scal... 3563 [import pandas as pd, import matplotlib.pyplot... 3444 [%%time, last_activity = np.max(events.time.va... 4037 [df_filter['Awards'].str.split('.').str.len().... 1482 [from keras import applications, from keras.mo... 29 [len(filter_movies.index.unique())] 2868 [test_X = dft1[columns]] 4950 [ax = df.Income.hist(bins=25), _ = (ax.set_tit... 1208 [W_fc2 = weight_variable([1024, 10]), b_fc2 = ... 791 [folds = 3, batch_size_nn = 16, batch_size_lst... 4405 [iris = datasets.load_iris(), X = iris.data, y... 5711 [df = pd.read_csv('refugee_data.csv')] 3623 [df.shape] 5189 [velo1_17 = pab17.groupby(['gameday_link','pit... 3235 [import csv, import itertools, with open('./Da... 2945 [f2 = open('census.csv', 'r'), census = list(c... 5372 [zips = pd.Series(zipcodes), zips.value_counts()] 409 [] 4971 [def covariance(X):, X_mean = np.mean(X,axis=0... 4506 [import numpy as np, import keras, from keras.... 4843 [print("Training ..."), n_epochs=100, batches_... 157 [def parse_async_meta(async_result):, """Parse... 907 [hide_code, plt.figure(figsize=(12,5)), x, y =... 5485 [import utils.dc_ccd as ccd] 3486 [A = build_singularity_matrix(A_source, B_vort... 11 [pivot_table['101 Dalmatians (1996)'].notnull(... 3001 [visualize_aam(aam)] 5664 [scatter(y_test, pred, 0.5)] 1767 [def discard_address_number(address_string):, ... 4656 [moving_average = (runningMeanFast (counts_dat... text 1553 [n_comps = 1 + np.argmax(vc > 0.95), data_scal... 3563 [import pandas as pd, import matplotlib.pyplot... 3444 [%%time, last_activity = np.max(events.time.va... 4037 [df_filter['Awards'].str.split('.').str.len().... 1482 [from keras import applications, from keras.mo... 29 [len(filter_movies.index.unique())] 2868 [test_X = dft1[columns]] 4950 [ax = df.Income.hist(bins=25), _ = (ax.set_tit... 1208 [W_fc2 = weight_variable([1024, 10]), b_fc2 = ... 791 [folds = 3, batch_size_nn = 16, batch_size_lst... 4405 [iris = datasets.load_iris(), X = iris.data, y... 5711 [df = pd.read_csv('refugee_data.csv')] 3623 [df.shape] 5189 [velo1_17 = pab17.groupby(['gameday_link','pit... 3235 [import csv, import itertools, with open('./Da... 2945 [f2 = open('census.csv', 'r'), census = list(c... 5372 [zips = pd.Series(zipcodes), zips.value_counts()] 409 [] 4971 [def covariance(X):, X_mean = np.mean(X,axis=0... 4506 [import numpy as np, import keras, from keras.... 4843 [print("Training ..."), n_epochs=100, batches_... 157 [def parse_async_meta(async_result):, """Parse... 907 [hide_code, plt.figure(figsize=(12,5)), x, y =... 5485 [import utils.dc_ccd as ccd] 3486 [A = build_singularity_matrix(A_source, B_vort... 11 [pivot_table['101 Dalmatians (1996)'].notnull(... 3001 [visualize_aam(aam)] 5664 [scatter(y_test, pred, 0.5)] 1767 [def discard_address_number(address_string):, ... 4656 [moving_average = (runningMeanFast (counts_dat...
0.014814
315,506,688
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
bdf6442c4cc3a9fa4e56ac8215b7a972
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1]
Out[1]: ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters'] ["l_cols = ['user_id','movie_id','rating']", "r_cols = ['movie_id','title']", "l = pd.read_csv('u.data', sep='\\t', names=l_cols, usecols=range(3))", 'r = pd.read_csv(\'u.item\', sep=\'|\', names=r_cols, usecols=range(2), encoding = "ISO-8859-1") ## contains unicode characters']
0.004782
315,637,760
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
55f83d973a7068840eb756a72e6b6589
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = df["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text
--------------------------------------------------------------------------- NameError Traceback (most recent call last) File <ipython-input-1-148621c711c6>:4  1 train_features.text[1]  2 from sklearn.feature_extraction.text import TfidfVectorizer ----> 4 text = df["code_line_before"]  5 # vectorizer = TfidfVectorizer()  6 # X = vectorizer.fit_transform(corpus)  8 text NameError: name 'df' is not defined Error: name 'df' is not defined
0.012583
315,768,832
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": null, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
90dd25410231670285015c646b141bff
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text
Out[1]: 0 0 1 [import numpy as np] 2 [r = pd.read_csv('u.item', sep='|', names=r_co... 3 [l.head()] 4 [r.head()] ... 5828 [plt.show()] 5829 [print("The average accuracy among all subject... 5830 [srm.fit(movie_data)] 5831 [image_data_shared[subject] = stats.zscore(ima... 5832 [cm[subject] = cm[subject].astype('float') / c... Name: code_line_before, Length: 5833, dtype: object 0 0 1 [import numpy as np] 2 [r = pd.read_csv('u.item', sep='|', names=r_co... 3 [l.head()] 4 [r.head()] ... 5828 [plt.show()] 5829 [print("The average accuracy among all subject... 5830 [srm.fit(movie_data)] 5831 [image_data_shared[subject] = stats.zscore(ima... 5832 [cm[subject] = cm[subject].astype('float') / c... Name: code_line_before, Length: 5833, dtype: object
0.005078
315,768,832
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
0f90bec8b524ec4221c6fdbff7bf0d3c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) type(text)
Out[1]: pandas.core.series.Series <class 'pandas.core.series.Series'>
0.005351
315,899,904
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
221cc05190145a94dc4e5eda4e44cd5b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) str(text)
Out[1]: '0 0\n1 [import numpy as np]\n2 [r = pd.read_csv(\'u.item\', sep=\'|\', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print("The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype(\'float\') / c...\nName: code_line_before, Length: 5833, dtype: object' '0 0\n1 [import numpy as np]\n2 [r = pd.read_csv(\'u.item\', sep=\'|\', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print("The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype(\'float\') / c...\nName: code_line_before, Length: 5833, dtype: object'
0.006071
315,899,904
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a0f22d645a3c93a88acc5db2f8146a9f
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text
Out[1]: 0 0 1 [import numpy as np] 2 [r = pd.read_csv('u.item', sep='|', names=r_co... 3 [l.head()] 4 [r.head()] ... 5828 [plt.show()] 5829 [print("The average accuracy among all subject... 5830 [srm.fit(movie_data)] 5831 [image_data_shared[subject] = stats.zscore(ima... 5832 [cm[subject] = cm[subject].astype('float') / c... Name: code_line_before, Length: 5833, dtype: object 0 0 1 [import numpy as np] 2 [r = pd.read_csv('u.item', sep='|', names=r_co... 3 [l.head()] 4 [r.head()] ... 5828 [plt.show()] 5829 [print("The average accuracy among all subject... 5830 [srm.fit(movie_data)] 5831 [image_data_shared[subject] = stats.zscore(ima... 5832 [cm[subject] = cm[subject].astype('float') / c... Name: code_line_before, Length: 5833, dtype: object
0.006427
315,899,904
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
fe89ead02cf5d39d54bd67ff390313dc
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text.apply(lambda x: " ".join(x))
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) File <ipython-input-1-9515e935ac4b>:8  4 text = train_features["code_line_before"]  5 # vectorizer = TfidfVectorizer()  6 # X = vectorizer.fit_transform(corpus) ----> 8 text.apply(lambda x: " ".join(x)) File /usr/local/lib/python3.9/site-packages/pandas/core/series.py:4917, in Series.apply(self, func, convert_dtype, args, by_row, **kwargs)  4789 def apply(  4790 self,  4791 func: AggFuncType,  (...)  4796 **kwargs,  4797 ) -> DataFrame | Series:  4798  """  4799  Invoke function on values of Series.  4800  (...)  4915  dtype: float64  4916  """ -> 4917 return SeriesApply(  4918  self,  4919  func,  4920  convert_dtype=convert_dtype,  4921  by_row=by_row,  4922  args=args,  4923  kwargs=kwargs,  4924  ).apply() File /usr/local/lib/python3.9/site-packages/pandas/core/apply.py:1427, in SeriesApply.apply(self)  1424 return self.apply_compat()  1426 # self.func is Callable -> 1427 return self.apply_standard() File /usr/local/lib/python3.9/site-packages/pandas/core/apply.py:1507, in SeriesApply.apply_standard(self)  1501 # row-wise access  1502 # apply doesn't have a `na_action` keyword and for backward compat reasons  1503 # we need to give `na_action="ignore"` for categorical data.  1504 # TODO: remove the `na_action="ignore"` when that default has been changed in  1505 # Categorical (GH51645).  1506 action = "ignore" if isinstance(obj.dtype, CategoricalDtype) else None -> 1507 mapped = obj._map_values(  1508  mapper=curried, na_action=action, convert=self.convert_dtype  1509 )  1511 if len(mapped) and isinstance(mapped[0], ABCSeries):  1512 # GH#43986 Need to do list(mapped) in order to get treated as nested  1513 # See also GH#25959 regarding EA support  1514 return obj._constructor_expanddim(list(mapped), index=obj.index) File /usr/local/lib/python3.9/site-packages/pandas/core/base.py:921, in IndexOpsMixin._map_values(self, mapper, na_action, convert)  918 if isinstance(arr, ExtensionArray):  919 return arr.map(mapper, na_action=na_action) --> 921 return algorithms.map_array(arr, mapper, na_action=na_action, convert=convert) File /usr/local/lib/python3.9/site-packages/pandas/core/algorithms.py:1743, in map_array(arr, mapper, na_action, convert)  1741 values = arr.astype(object, copy=False)  1742 if na_action is None: -> 1743 return lib.map_infer(values, mapper, convert=convert)  1744 else:  1745 return lib.map_infer_mask(  1746 values, mapper, mask=isna(values).view(np.uint8), convert=convert  1747 ) File lib.pyx:2972, in pandas._libs.lib.map_infer() File <ipython-input-1-9515e935ac4b>:8, in <lambda>(x)  4 text = train_features["code_line_before"]  5 # vectorizer = TfidfVectorizer()  6 # X = vectorizer.fit_transform(corpus) ----> 8 text.apply(lambda x: " ".join(x)) TypeError: can only join an iterable Error: can only join an iterable
0.286633
332,152,832
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
8752bf4554dcbdf2b85e34dd4d2ec962
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text.apply(lambda x: " ".join(list(x))
 File <ipython-input-1-7b4151cc6089>:8  text.apply(lambda x: " ".join(list(x))  ^ SyntaxError: unexpected EOF while parsing Error: None
0.003906
332,152,832
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
b6a1b6c945dfeb020b2c0d835db1f1c1
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.text[1] from sklearn.feature_extraction.text import TfidfVectorizer text = train_features["code_line_before"] # vectorizer = TfidfVectorizer() # X = vectorizer.fit_transform(corpus) text.apply(lambda x: " ".join(list(x)))
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) File <ipython-input-1-ba5fe71dd87a>:8  4 text = train_features["code_line_before"]  5 # vectorizer = TfidfVectorizer()  6 # X = vectorizer.fit_transform(corpus) ----> 8 text.apply(lambda x: " ".join(list(x))) File /usr/local/lib/python3.9/site-packages/pandas/core/series.py:4917, in Series.apply(self, func, convert_dtype, args, by_row, **kwargs)  4789 def apply(  4790 self,  4791 func: AggFuncType,  (...)  4796 **kwargs,  4797 ) -> DataFrame | Series:  4798  """  4799  Invoke function on values of Series.  4800  (...)  4915  dtype: float64  4916  """ -> 4917 return SeriesApply(  4918  self,  4919  func,  4920  convert_dtype=convert_dtype,  4921  by_row=by_row,  4922  args=args,  4923  kwargs=kwargs,  4924  ).apply() File /usr/local/lib/python3.9/site-packages/pandas/core/apply.py:1427, in SeriesApply.apply(self)  1424 return self.apply_compat()  1426 # self.func is Callable -> 1427 return self.apply_standard() File /usr/local/lib/python3.9/site-packages/pandas/core/apply.py:1507, in SeriesApply.apply_standard(self)  1501 # row-wise access  1502 # apply doesn't have a `na_action` keyword and for backward compat reasons  1503 # we need to give `na_action="ignore"` for categorical data.  1504 # TODO: remove the `na_action="ignore"` when that default has been changed in  1505 # Categorical (GH51645).  1506 action = "ignore" if isinstance(obj.dtype, CategoricalDtype) else None -> 1507 mapped = obj._map_values(  1508  mapper=curried, na_action=action, convert=self.convert_dtype  1509 )  1511 if len(mapped) and isinstance(mapped[0], ABCSeries):  1512 # GH#43986 Need to do list(mapped) in order to get treated as nested  1513 # See also GH#25959 regarding EA support  1514 return obj._constructor_expanddim(list(mapped), index=obj.index) File /usr/local/lib/python3.9/site-packages/pandas/core/base.py:921, in IndexOpsMixin._map_values(self, mapper, na_action, convert)  918 if isinstance(arr, ExtensionArray):  919 return arr.map(mapper, na_action=na_action) --> 921 return algorithms.map_array(arr, mapper, na_action=na_action, convert=convert) File /usr/local/lib/python3.9/site-packages/pandas/core/algorithms.py:1743, in map_array(arr, mapper, na_action, convert)  1741 values = arr.astype(object, copy=False)  1742 if na_action is None: -> 1743 return lib.map_infer(values, mapper, convert=convert)  1744 else:  1745 return lib.map_infer_mask(  1746 values, mapper, mask=isna(values).view(np.uint8), convert=convert  1747 ) File lib.pyx:2972, in pandas._libs.lib.map_infer() File <ipython-input-1-ba5fe71dd87a>:8, in <lambda>(x)  4 text = train_features["code_line_before"]  5 # vectorizer = TfidfVectorizer()  6 # X = vectorizer.fit_transform(corpus) ----> 8 text.apply(lambda x: " ".join(list(x))) TypeError: 'int' object is not iterable Error: 'int' object is not iterable
0.033269
332,546,048
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
809bede31fde9db9ae1d6bdf17c8212e
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0]["code_line_after"] = [] test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-071df62a9534>:18  14 test_features.index = range(test_features.shape[0])  17 train_features.fillna(0, inplace=True) ---> 18 train_features[train_features["code_line_after"] == 0]["code_line_after"] = []  20 test_features.fillna(0, inplace=True)  22 validation_features.fillna(0,inplace=True) File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:4311, in DataFrame.__setitem__(self, key, value)  4308 self._setitem_array([key], value)  4309 else:  4310 # set column -> 4311 self._set_item(key, value) File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:4524, in DataFrame._set_item(self, key, value)  4514 def _set_item(self, key, value) -> None:  4515  """  4516  Add series to DataFrame in specified column.  4517  (...)  4522  ensure homogeneity.  4523  """ -> 4524 value, refs = self._sanitize_column(value)  4526 if (  4527 key in self.columns  4528 and value.ndim == 1  4529 and not isinstance(value.dtype, ExtensionDtype)  4530 ):  4531 # broadcast across multiple columns if necessary  4532 if not self.columns.is_unique or isinstance(self.columns, MultiIndex): File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:5266, in DataFrame._sanitize_column(self, value)  5263 return _reindex_for_setitem(value, self.index)  5265 if is_list_like(value): -> 5266 com.require_length_match(value, self.index)  5267 arr = sanitize_array(value, self.index, copy=True, allow_2d=True)  5268 if (  5269 isinstance(value, Index)  5270 and value.dtype == "object"  (...)  5273 # TODO: Remove kludge in sanitize_array for string mode when enforcing  5274 # this deprecation File /usr/local/lib/python3.9/site-packages/pandas/core/common.py:573, in require_length_match(data, index)  569 """  570 Check the length of data matches the length of the index.  571 """  572 if len(data) != len(index): --> 573 raise ValueError(  574 "Length of values "  575 f"({len(data)}) "  576 "does not match length of index "  577 f"({len(index)})"  578 ) ValueError: Length of values (0) does not match length of index (403) Error: Length of values (0) does not match length of index (403)
0.148244
361,746,432
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
226ee1e90d8779b5bd54c121add3d376
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0] test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21)
0.100984
378,081,280
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d2b2245a11994aa44ebb570e10f3e749
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = [] test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-82f9041a854b>:18  14 test_features.index = range(test_features.shape[0])  17 train_features.fillna(0, inplace=True) ---> 18 train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = []  20 test_features.fillna(0, inplace=True)  22 validation_features.fillna(0,inplace=True) File /usr/local/lib/python3.9/site-packages/pandas/core/indexing.py:911, in _LocationIndexer.__setitem__(self, key, value)  908 self._has_valid_setitem_indexer(key)  910 iloc = self if self.name == "iloc" else self.obj.iloc --> 911 iloc._setitem_with_indexer(indexer, value, self.name) File /usr/local/lib/python3.9/site-packages/pandas/core/indexing.py:1932, in _iLocIndexer._setitem_with_indexer(self, indexer, value, name)  1929 indexer, missing = convert_missing_indexer(indexer)  1931 if missing: -> 1932 self._setitem_with_indexer_missing(indexer, value)  1933 return  1935 if name == "loc":  1936 # must come after setting of missing File /usr/local/lib/python3.9/site-packages/pandas/core/indexing.py:2306, in _iLocIndexer._setitem_with_indexer_missing(self, indexer, value)  2303 if is_list_like_indexer(value):  2304 # must have conforming columns  2305 if len(value) != len(self.obj.columns): -> 2306 raise ValueError("cannot set a row with mismatched columns")  2308 value = Series(value, index=self.obj.columns, name=indexer)  2310 if not len(self.obj):  2311 # We will ignore the existing dtypes instead of using  2312 # internals.concat logic ValueError: cannot set a row with mismatched columns Error: cannot set a row with mismatched columns
0.120661
378,507,264
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
83309e2e13f2a6caa3ffe80831f1d05b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0]["code_line_after"] = [] test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-071df62a9534>:18  14 test_features.index = range(test_features.shape[0])  17 train_features.fillna(0, inplace=True) ---> 18 train_features[train_features["code_line_after"] == 0]["code_line_after"] = []  20 test_features.fillna(0, inplace=True)  22 validation_features.fillna(0,inplace=True) File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:4311, in DataFrame.__setitem__(self, key, value)  4308 self._setitem_array([key], value)  4309 else:  4310 # set column -> 4311 self._set_item(key, value) File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:4524, in DataFrame._set_item(self, key, value)  4514 def _set_item(self, key, value) -> None:  4515  """  4516  Add series to DataFrame in specified column.  4517  (...)  4522  ensure homogeneity.  4523  """ -> 4524 value, refs = self._sanitize_column(value)  4526 if (  4527 key in self.columns  4528 and value.ndim == 1  4529 and not isinstance(value.dtype, ExtensionDtype)  4530 ):  4531 # broadcast across multiple columns if necessary  4532 if not self.columns.is_unique or isinstance(self.columns, MultiIndex): File /usr/local/lib/python3.9/site-packages/pandas/core/frame.py:5266, in DataFrame._sanitize_column(self, value)  5263 return _reindex_for_setitem(value, self.index)  5265 if is_list_like(value): -> 5266 com.require_length_match(value, self.index)  5267 arr = sanitize_array(value, self.index, copy=True, allow_2d=True)  5268 if (  5269 isinstance(value, Index)  5270 and value.dtype == "object"  (...)  5273 # TODO: Remove kludge in sanitize_array for string mode when enforcing  5274 # this deprecation File /usr/local/lib/python3.9/site-packages/pandas/core/common.py:573, in require_length_match(data, index)  569 """  570 Check the length of data matches the length of the index.  571 """  572 if len(data) != len(index): --> 573 raise ValueError(  574 "Length of values "  575 f"({len(data)}) "  576 "does not match length of index "  577 f"({len(index)})"  578 ) ValueError: Length of values (0) does not match length of index (403) Error: Length of values (0) does not match length of index (403)
0.124196
383,619,072
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
51126dba96fbe14ab31286a9ef63ffa4
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0]["code_line_after"] = "" test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21) <ipython-input-1-d1263862e539>:18: SettingWithCopyWarning: A value is trying to be set on a copy of a slice from a DataFrame. Try using .loc[row_indexer,col_indexer] = value instead See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy train_features[train_features["code_line_after"] == 0]["code_line_after"] = ""
0.032139
385,126,400
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
f45a75bfa3a86fc09eb57c56a0fb2773
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features.fillna(0, inplace=True) train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = "" test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21) <ipython-input-1-9d5e1f008ffb>:18: SettingWithCopyWarning: A value is trying to be set on a copy of a slice from a DataFrame See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = ""
0.032322
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
75e3740473daa54dd80c91a896a484cf
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# train_features.drop(columns=["filename"]) train_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object')
0.004823
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
b4f68eafe8061bc6598815c6570e21b7
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# train_features.drop(columns=["filename"]) train_features
Out[1]: filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns] filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns]
0.02972
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
668de259a1e2408bfec4e9c2076f099b
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
# train_features.drop(columns=["filename"]) train_features["code_line_after"]
Out[1]: 0 [l_cols = ['user_id','movie_id','rating']] 1 [l.head()] 2 [r.head()] 3 [movies = pd.merge(l,r)] 4 [movies.head()] ... 5828 [srm = brainiak.funcalign.srm.DetSRM(n_iter=10... 5829 [image_data_shared = srm.transform(image_data)] 5830 [accuracy = np.zeros((subjects,))] 5831 [plot_confusion_matrix(cm, title="Confusion ma... 5832 0 Name: code_line_after, Length: 5833, dtype: object 0 [l_cols = ['user_id','movie_id','rating']] 1 [l.head()] 2 [r.head()] 3 [movies = pd.merge(l,r)] 4 [movies.head()] ... 5828 [srm = brainiak.funcalign.srm.DetSRM(n_iter=10... 5829 [image_data_shared = srm.transform(image_data)] 5830 [accuracy = np.zeros((subjects,))] 5831 [plot_confusion_matrix(cm, title="Confusion ma... 5832 0 Name: code_line_after, Length: 5833, dtype: object
0.006393
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
ea52d7311f599a97f1c7e1e1873f4b64
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features
Out[1]: filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns] filename cell_type ... save_results comment_only 0 nb_54880.ipynb code ... 0 0 1 nb_54880.ipynb code ... 0 0 2 nb_54880.ipynb code ... 0 0 3 nb_54880.ipynb code ... 0 0 4 nb_54880.ipynb code ... 0 0 ... ... ... ... ... ... 5828 nb_95821.ipynb code ... 0 0 5829 nb_95821.ipynb code ... 0 0 5830 nb_95821.ipynb code ... 0 0 5831 nb_95821.ipynb code ... 0 0 5832 nb_95821.ipynb code ... 0 0 [5833 rows x 32 columns]
0.029281
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
21e517922e381fbe6281f18b2797c0b3
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features.columns
Out[1]: Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object') Index(['filename', 'cell_type', 'cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'text/plain', 'image/png', 'text/html', 'execute_result', 'display_data', 'stream', 'error', 'text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading', 'packages_info', 'primary_label', 'helper_functions', 'load_data', 'data_exploration', 'data_preprocessing', 'evaluation', 'modelling', 'prediction', 'result_visualization', 'save_results', 'comment_only'], dtype='object')
0.004964
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
3af726819da8f96f8c19d3b3829f83a8
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features["packages_info"]
Out[1]: 0 [**pandas** is a Python package providing fast... 1 [] 2 [] 3 [] 4 [] ... 5828 [] 5829 [] 5830 [] 5831 [] 5832 [] Name: packages_info, Length: 5833, dtype: object 0 [**pandas** is a Python package providing fast... 1 [] 2 [] 3 [] 4 [] ... 5828 [] 5829 [] 5830 [] 5831 [] 5832 [] Name: packages_info, Length: 5833, dtype: object
0.006016
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
82b6ae955d94647a0110c001cde71492
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features["packages_info"].unique()
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) File <ipython-input-1-8561fb9650bc>:1 ----> 1 train_features["packages_info"].unique() File /usr/local/lib/python3.9/site-packages/pandas/core/series.py:2407, in Series.unique(self)  2344 def unique(self) -> ArrayLike: # pylint: disable=useless-parent-delegation  2345  """  2346  Return unique values of Series object.  2347  (...)  2405  Categories (3, object): ['a' < 'b' < 'c']  2406  """ -> 2407 return super().unique() File /usr/local/lib/python3.9/site-packages/pandas/core/base.py:1025, in IndexOpsMixin.unique(self)  1023 result = values.unique()  1024 else: -> 1025 result = algorithms.unique1d(values)  1026 return result File /usr/local/lib/python3.9/site-packages/pandas/core/algorithms.py:401, in unique(values)  307 def unique(values):  308  """  309  Return unique values based on a hash table.  310  (...)  399  array([('a', 'b'), ('b', 'a'), ('a', 'c')], dtype=object)  400  """ --> 401 return unique_with_mask(values) File /usr/local/lib/python3.9/site-packages/pandas/core/algorithms.py:440, in unique_with_mask(values, mask)  438 table = hashtable(len(values))  439 if mask is None: --> 440 uniques = table.unique(values)  441 uniques = _reconstruct_data(uniques, original.dtype, original)  442 return uniques File pandas/_libs/hashtable_class_helper.pxi:7248, in pandas._libs.hashtable.PyObjectHashTable.unique() File pandas/_libs/hashtable_class_helper.pxi:7195, in pandas._libs.hashtable.PyObjectHashTable._unique() TypeError: unhashable type: 'list' Error: unhashable type: 'list'
0.056429
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
aac3d7040c687fae59e921071c3bcf6a
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features["packages_info"] != []
--------------------------------------------------------------------------- ValueError Traceback (most recent call last) File <ipython-input-1-3e6aa13d7bf3>:1 ----> 1 train_features["packages_info"] != [] File /usr/local/lib/python3.9/site-packages/pandas/core/ops/common.py:76, in _unpack_zerodim_and_defer.<locals>.new_method(self, other)  72 return NotImplemented  74 other = item_from_zerodim(other) ---> 76 return method(self, other) File /usr/local/lib/python3.9/site-packages/pandas/core/arraylike.py:44, in OpsMixin.__ne__(self, other)  42 @unpack_zerodim_and_defer("__ne__")  43 def __ne__(self, other): ---> 44 return self._cmp_method(other, operator.ne) File /usr/local/lib/python3.9/site-packages/pandas/core/series.py:6119, in Series._cmp_method(self, other, op)  6116 lvalues = self._values  6117 rvalues = extract_array(other, extract_numpy=True, extract_range=True) -> 6119 res_values = ops.comparison_op(lvalues, rvalues, op)  6121 return self._construct_result(res_values, name=res_name) File /usr/local/lib/python3.9/site-packages/pandas/core/ops/array_ops.py:321, in comparison_op(left, right, op)  316 if isinstance(rvalues, (np.ndarray, ABCExtensionArray)):  317 # TODO: make this treatment consistent across ops and classes.  318 # We are not catching all listlikes here (e.g. frozenset, tuple)  319 # The ambiguous case is object-dtype. See GH#27803  320 if len(lvalues) != len(rvalues): --> 321 raise ValueError(  322 "Lengths must match to compare", lvalues.shape, rvalues.shape  323 )  325 if should_extension_dispatch(lvalues, rvalues) or (  326 (isinstance(rvalues, (Timedelta, BaseOffset, Timestamp)) or right is NaT)  327 and lvalues.dtype != object  328 ):  329 # Call the method on lvalues  330 res_values = op(lvalues, rvalues) ValueError: ('Lengths must match to compare', (5833,), (0,)) Error: ('Lengths must match to compare', (5833,), (0,))
0.063223
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
11a44f46de86ea08736f64fabb4e6a43
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features["packages_info"] != "[]""
 File <ipython-input-1-a8d2718a0e1b>:1  train_features["packages_info"] != "[]""  ^ SyntaxError: EOL while scanning string literal Error: None
0.005492
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
a4235924eb30ad6c7237c76ee75bb80c
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
train_features["packages_info"] != "[]"
Out[1]: 0 True 1 True 2 True 3 True 4 True ... 5828 True 5829 True 5830 True 5831 True 5832 True Name: packages_info, Length: 5833, dtype: bool 0 True 1 True 2 True 3 True 4 True ... 5828 True 5829 True 5830 True 5831 True 5832 True Name: packages_info, Length: 5833, dtype: bool
0.00583
386,199,552
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
c64fbf3512950e22e4e4c8c3ec1a13e5
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features[['text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading']].fillna([], inplace=True) train_features.fillna(0, inplace=True) # train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = "" test_features.fillna(0, inplace=True) validation_features.fillna(0,inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) File <ipython-input-1-61dfcdd20181>:17  13 validation_features.index = range(validation_features.shape[0])  14 test_features.index = range(test_features.shape[0]) ---> 17 train_features[['text', 'comment',  18  'code_line_before', 'code_line_after', 'markdown_heading']].fillna([], inplace=True)  19 train_features.fillna(0, inplace=True)  21 # train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = "" File /usr/local/lib/python3.9/site-packages/pandas/core/generic.py:7293, in NDFrame.fillna(self, value, method, axis, inplace, limit, downcast)  7286 if ctr <= ref_count:  7287 warnings.warn(  7288 _chained_assignment_warning_method_msg,  7289 FutureWarning,  7290 stacklevel=2,  7291 ) -> 7293 value, method = validate_fillna_kwargs(value, method)  7294 if method is not None:  7295 warnings.warn(  7296 f"{type(self).__name__}.fillna with 'method' is deprecated and "  7297 "will raise in a future version. Use obj.ffill() or obj.bfill() "  (...)  7300 stacklevel=find_stack_level(),  7301 ) File /usr/local/lib/python3.9/site-packages/pandas/util/_validators.py:299, in validate_fillna_kwargs(value, method, validate_scalar_dict_value)  297 elif value is not None and method is None:  298 if validate_scalar_dict_value and isinstance(value, (list, tuple)): --> 299 raise TypeError(  300 '"value" parameter must be a scalar or dict, but '  301 f'you passed a "{type(value).__name__}"'  302 )  304 elif value is not None and method is not None:  305 raise ValueError("Cannot specify both 'value' and 'method'.") TypeError: "value" parameter must be a scalar or dict, but you passed a "list" Error: "value" parameter must be a scalar or dict, but you passed a "list"
0.303702
408,780,800
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
d6892ac811d19bf53671c1c9d4539106
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features[['text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading']].fillna("", inplace=True) train_features.fillna(0, inplace=True) # train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = "" test_features.fillna(0, inplace=True) validation_features.fillna(0, inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21) <ipython-input-1-0f954cf76115>:17: SettingWithCopyWarning: A value is trying to be set on a copy of a slice from a DataFrame See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy train_features[['text', 'comment',
0.031623
422,273,024
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 5457229, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
7c1756b2e9c89787cc63271ace4740ab
388ef554-e3e7-4410-89ac-d6ad4aeaec6c
import pandas as pd import lightgbm as lgb from sklearn.metrics import accuracy_score from sklearn.model_selection import train_test_split features_path = 'data/task2/' test_features = pd.read_pickle(features_path+'test_features.pkl') train_features = pd.read_pickle(features_path+'train_features.pkl') validation_features = pd.read_pickle(features_path+'validation_features.pkl') train_features.index = range(train_features.shape[0]) validation_features.index = range(validation_features.shape[0]) test_features.index = range(test_features.shape[0]) train_features[['text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading']] = train_features[['text', 'comment', 'code_line_before', 'code_line_after', 'markdown_heading']].fillna("", inplace=True) train_features.fillna(0, inplace=True) # train_features[train_features["code_line_after"] == 0].loc["code_line_after"] = "" test_features.fillna(0, inplace=True) validation_features.fillna(0, inplace=True) print(train_features.shape) print(validation_features.shape) print(test_features.shape)
(5833, 32) (1927, 32) (1918, 21) <ipython-input-1-9d3507acdcd8>:18: SettingWithCopyWarning: A value is trying to be set on a copy of a slice from a DataFrame See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy 'code_line_before', 'code_line_after', 'markdown_heading']] = train_features[['text', 'comment',
0.122979
424,005,632
{ "CountVectorizer": null, "DF": null, "MultinomialNB": null, "RandomForestClassifier": null, "Readliner": null, "TfidfTransformer": null, "TfidfVectorizer": { "name": "TfidfVectorizer", "size": 2008, "type": "type", "value": "<class 'sklearn.feature_extraction.text.TfidfVectorizer'>" }, "Timestamp": null, "X": { "name": "X", "size": 48, "type": "csr_matrix", "value": " (0, 2)\t0.5773502691896258\n (0, 1)\t0.5773502691896258\n (0, 0)\t0.5773502691896258" }, "X1": null, "X2": null, "X3": null, "X_columns": null, "X_columns_text": null, "X_test": null, "X_train": null, "X_val": null, "accuracy_score": { "name": "accuracy_score", "size": 136, "type": "function", "value": "<function accuracy_score at 0xffff7244be50>" }, "act": null, "action": null, "action_counts": null, "action_durations": null, "action_name": null, "action_name_col": null, "action_time": null, "action_time_col": null, "actions": null, "actions_per_day": null, "ax": null, "class_map": null, "clf": { "name": "clf", "size": 48, "type": "LGBMClassifier", "value": "LGBMClassifier()" }, "clf_c": null, "clf_ft": null, "cnt": null, "contents": null, "corpus": { "name": "corpus", "size": 64, "type": "list", "value": "['I want some pitsa']" }, "corrupt": null, "count": null, "count_all": null, "counts": null, "curr_session": null, "cv": null, "cv_c": null, "cv_ft": null, "daily_actions": null, "daily_counts": null, "data": null, "data_path": null, "datetime": null, "day": null, "day_counts": null, "deltas": null, "df": null, "df2": null, "df_temp": null, "df_timed": null, "df_top_users": null, "durations": null, "end_mask": null, "f": null, "f1_score": { "name": "f1_score", "size": 136, "type": "function", "value": "<function f1_score at 0xffff72456670>" }, "f_statistic": null, "features_path": { "name": "features_path", "size": 60, "type": "str", "value": "data/task2/" }, "fig": null, "generate_tokens": null, "group": null, "grouped": null, "hstack": null, "i": null, "ind": null, "krdl": null, "l": null, "line": null, "lines": null, "lines2": null, "mask": null, "mean_duration": null, "median_duration": null, "mode_duration": null, "myfile": null, "myzip": null, "name": null, "nb_prd": null, "new_row": null, "p_test": null, "p_val": null, "p_value": null, "parse": null, "parsed": null, "partial": null, "parts": null, "pattern": null, "pivot_counts": null, "pred": { "name": "pred", "size": 15528, "type": "ndarray", "value": "['helper_functions' 'load_data' 'data_exploration' ... 'data_exploration'\n 'data_exploration' 'data_exploration']" }, "prepare_X": null, "prepare_dataset_RF": null, "prepare_y": null, "r": null, "repeats": null, "rfclf": null, "row": null, "session_df": null, "session_durations": null, "session_num": null, "session_num_col": null, "split_lines": null, "stats": null, "t_stat": null, "target": { "name": "target", "size": 416963, "type": "Series", "value": "0 helper_functions\n1 load_data\n2 data_exploration\n3 data_exploration\n4 data_preprocessing\n ... \n5828 evaluation\n5829 modelling\n5830 data_preprocessing\n5831 modelling\n5832 evaluation\nName: primary_label, Length: 5833, dtype: object" }, "target_drop": { "name": "target_drop", "size": 152, "type": "list", "value": "['primary_label', 'load_data', 'helper_functions', 'data_preprocessing', 'data_exploration', 'modelling', 'prediction', 'evaluation', 'result_visualization', 'save_results', 'comment_only']" }, "test_features": { "name": "test_features", "size": 1546797, "type": "DataFrame", "value": " filename ... packages_info\n0 nb_28545.ipynb ... [harmonic ======== Planning, Matplotlib strive...\n1 nb_28545.ipynb ... []\n2 nb_28545.ipynb ... []\n3 nb_28545.ipynb ... []\n4 nb_28545.ipynb ... []\n... ... ... ...\n1913 nb_96779.ipynb ... []\n1914 nb_96779.ipynb ... []\n1915 nb_96779.ipynb ... []\n1916 nb_96779.ipynb ... []\n1917 nb_96779.ipynb ... []\n\n[1918 rows x 21 columns]" }, "text": { "name": "text", "size": 541424, "type": "Series", "value": "0 0\n1 [import numpy as np]\n2 [r = pd.read_csv('u.item', sep='|', names=r_co...\n3 [l.head()]\n4 [r.head()]\n ... \n5828 [plt.show()]\n5829 [print(\"The average accuracy among all subject...\n5830 [srm.fit(movie_data)]\n5831 [image_data_shared[subject] = stats.zscore(ima...\n5832 [cm[subject] = cm[subject].astype('float') / c...\nName: code_line_before, Length: 5833, dtype: object" }, "text_counts": null, "tf_transformer": null, "tf_transformer_c": null, "tf_transformer_ft": null, "time": null, "tokenize_py": null, "top_user_daily_actions": null, "top_users": null, "tqdm": null, "train_columns": { "name": "train_columns", "size": 152, "type": "list", "value": "['cell_number', 'execution_count', 'linesofcomment', 'linesofcode', 'variable_count', 'function_count', 'display_data', 'stream', 'error']" }, "train_features": { "name": "train_features", "size": 2932213, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_54880.ipynb code ... 0 0\n1 nb_54880.ipynb code ... 0 0\n2 nb_54880.ipynb code ... 0 0\n3 nb_54880.ipynb code ... 0 0\n4 nb_54880.ipynb code ... 0 0\n... ... ... ... ... ...\n5828 nb_95821.ipynb code ... 0 0\n5829 nb_95821.ipynb code ... 0 0\n5830 nb_95821.ipynb code ... 0 0\n5831 nb_95821.ipynb code ... 0 0\n5832 nb_95821.ipynb code ... 0 0\n\n[5833 rows x 32 columns]" }, "train_test_split": { "name": "train_test_split", "size": 136, "type": "function", "value": "<function train_test_split at 0xffff71a97e50>" }, "transform": null, "txt": null, "user_daily_actions": null, "user_id": null, "user_id_col": null, "user_total_actions": null, "validation_features": { "name": "validation_features", "size": 1826459, "type": "DataFrame", "value": " filename cell_type ... save_results comment_only\n0 nb_128972.ipynb code ... 0 0\n1 nb_128972.ipynb code ... 0 0\n2 nb_128972.ipynb code ... 0 0\n3 nb_128972.ipynb code ... 0 0\n4 nb_128972.ipynb code ... 0 0\n... ... ... ... ... ...\n1922 nb_750781.ipynb code ... 0 0\n1923 nb_750781.ipynb code ... 0 0\n1924 nb_750781.ipynb code ... 0 0\n1925 nb_750781.ipynb code ... 0 0\n1926 nb_750781.ipynb code ... 0 0\n\n[1927 rows x 32 columns]" }, "vectorizer": { "name": "vectorizer", "size": 48, "type": "TfidfVectorizer", "value": "TfidfVectorizer()" }, "vectorizer1": null, "vectorizer2": null, "vectorizer3": null, "vstack": null, "weekday_counts": null, "weekday_df": null, "y_column": null, "y_columns": null, "y_train_multi": null, "y_train_primary": null, "y_val_multi": null, "y_val_primary": null }
823db64130a83ce99b38ed3297f76dd6