Module Import alias identifier Import alias identifier ImportFrom alias ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias Assign NameStore Call NameLoad Assign NameStore Call NameLoad Num Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index Num Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults Num Num Str NameLoad Num NameLoad body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr NameLoad keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Num For NameStore Call NameLoad AttributeLoad NameLoad attr body For NameStore Call NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index NameLoad If CompareIn AttributeLoad NameLoad attr TupleLoad Str Str body Assign NameStore Call NameLoad BinOpSub Num BinOpMult SubscriptLoad NameLoad Index NameLoad NameLoad Num orelse Assign NameStore Call NameLoad BinOpSub Call AttributeLoad NameLoad attr BinOpSub NameLoad SubscriptLoad NameLoad Index NameLoad AttributeLoad NameLoad attr Num Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index NameLoad SubscriptLoad NameLoad Index NameLoad If CompareIn AttributeLoad NameLoad attr TupleLoad Str Str body Assign NameStore Call NameLoad AttributeLoad NameLoad attr BinOpDiv NameLoad NameLoad orelse If CompareIn AttributeLoad NameLoad attr TupleLoad Str Str body Assign NameStore BinOpDiv NameLoad BinOpAdd NameLoad BinOpDiv Num BinOpMult Num AttributeLoad NameLoad attr If CompareIn AttributeLoad NameLoad attr TupleLoad Str Str body AugAssignMult NameStore SubscriptLoad NameLoad Index NameLoad orelse AugAssignMult NameStore Call AttributeLoad NameLoad attr BinOpSub SubscriptLoad NameLoad Index NameLoad NameLoad AugAssignAdd AttributeStore NameLoad attr BinOpMult NameLoad SubscriptLoad NameLoad Index NameLoad If AttributeLoad NameLoad attr body AugAssignAdd AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BinOpAdd Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list decorator_list FunctionDef arguments args defaults body For NameStore TupleLoad NameLoad NameLoad body For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword Num keyword NameLoad keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad NameLoad Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr NameLoad For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword Num For NameStore Call NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad NameLoad Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad Call NameLoad attr NameLoad NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad ExtSlice Slice Slice Num SubscriptLoad AttributeLoad NameLoad attr Index NameLoad Expr Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index CompareNotEq NameLoad Num Num For NameStore TupleLoad Str Str body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword NameLoad keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword NameLoad keyword Num keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr keyword Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call NameLoad For NameStore TupleLoad Str Str Str body Expr Call NameLoad NameLoad Lambda arguments args NameParam defaults Call NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr ListLoad ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num Assign NameStore ListLoad Num Num Num Num Num Assign NameStore Call NameLoad keyword Num keyword Num keyword NameLoad keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Call AttributeLoad NameLoad attr ListLoad ListLoad Num Num Call AttributeLoad NameLoad attr ListLoad Num Assign NameStore Call NameLoad keyword Num keyword Num keyword Dict Num Num keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Call AttributeLoad NameLoad attr ListLoad ListLoad Num Num Call AttributeLoad NameLoad attr ListLoad Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call NameLoad keyword Str Expr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad NameLoad keyword Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore ListLoad ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num Assign NameStore ListLoad Num Num Num Num Assign NameStore Call NameLoad keyword Num keyword Num keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call NameLoad keyword Num keyword Num keyword Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call NameLoad keyword Num keyword Num keyword Dict Num Num Num Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword Num Expr Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr ListLoad ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num Assign NameStore ListLoad Num Num Num Num Num Assign NameStore Call NameLoad keyword Dict Num Num Expr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr ListLoad ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num ListLoad Num Num Assign NameStore ListLoad Num Num Num Num Num Assign NameStore Call NameLoad keyword ListLoad Num Expr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call NameLoad keyword Str Expr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index CompareNotEq NameLoad Num Num For NameStore TupleLoad NameLoad NameLoad body For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword Num keyword NameLoad keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Call AttributeLoad NameLoad attr BinOpPow BinOpSub NameLoad NameLoad Num Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index CompareNotEq NameLoad Num Num For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword Num For NameStore Call NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Call AttributeLoad NameLoad attr BinOpPow BinOpSub NameLoad NameLoad Num Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index CompareNotEq NameLoad Num Num For NameStore TupleLoad Str Str body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword NameLoad keyword Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad For NameStore TupleLoad NameLoad NameLoad body Assign NameStore Call NameLoad keyword Num keyword NameLoad keyword NameLoad keyword Num keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr keyword Num decorator_list FunctionDef arguments args defaults body Assign NameStore Call NameLoad For NameStore TupleLoad Str body Expr Call NameLoad NameLoad Lambda arguments args NameParam defaults Call NameLoad NameLoad NameLoad NameLoad decorator_list
N/A N/A numpy np N/A scipy.sparse sp sklearn.utils.testing assert_less sklearn.utils.testing assert_greater sklearn.utils.testing assert_array_almost_equal assert_array_equal sklearn.utils.testing assert_almost_equal sklearn.utils.testing assert_raises sklearn.base ClassifierMixin sklearn.utils check_random_state sklearn.datasets load_iris sklearn.linear_model PassiveAggressiveClassifier sklearn.linear_model PassiveAggressiveRegressor N/A iris N/A load_iris N/A random_state N/A check_random_state 12 N/A indices N/A N/A np arange N/A N/A N/A iris data shape N/A 0 N/A N/A N/A random_state shuffle indices N/A X N/A N/A iris data N/A indices N/A y N/A N/A iris target N/A indices N/A X_csr N/A N/A sp csr_matrix X MyPassiveAggressive N/A ClassifierMixin N/A __init__ N/A N/A self C epsilon loss fit_intercept n_iter random_state N/A 1.0 0.01 hinge True 1 None N/A N/A N/A self C C N/A N/A self epsilon epsilon N/A N/A self loss loss N/A N/A self fit_intercept fit_intercept N/A N/A self n_iter n_iter N/A fit N/A N/A self X y N/A N/A N/A N/A n_samples n_features N/A X shape N/A N/A self w N/A N/A np zeros n_features dtype N/A np float64 N/A N/A self b 0.0 N/A t N/A range N/A self n_iter N/A N/A i N/A range n_samples N/A N/A p N/A N/A self project N/A X N/A i N/A N/A N/A self loss N/A hinge squared_hinge N/A N/A loss N/A max N/A 1 N/A N/A y N/A i p 0 N/A N/A loss N/A max N/A N/A N/A np abs N/A p N/A y N/A i N/A self epsilon 0 N/A sqnorm N/A N/A np dot N/A X N/A i N/A X N/A i N/A N/A N/A self loss N/A hinge epsilon_insensitive N/A N/A step N/A min N/A self C N/A loss sqnorm N/A N/A N/A N/A self loss N/A squared_hinge squared_epsilon_insensitive N/A N/A step N/A loss N/A sqnorm N/A 1.0 N/A 2 N/A self C N/A N/A N/A self loss N/A hinge squared_hinge N/A N/A step N/A y N/A i N/A N/A step N/A N/A np sign N/A N/A y N/A i p N/A N/A self w N/A step N/A X N/A i N/A N/A self fit_intercept N/A N/A N/A self b step N/A project N/A N/A self X N/A N/A N/A N/A N/A N/A np dot X N/A self w N/A self b N/A N/A test_classifier_accuracy N/A N/A N/A N/A N/A data N/A X X_csr N/A N/A fit_intercept N/A True False N/A N/A clf N/A PassiveAggressiveClassifier C 1.0 n_iter 30 fit_intercept fit_intercept random_state 0 N/A N/A N/A clf fit data y N/A score N/A N/A clf score data y N/A N/A assert_greater score 0.79 N/A test_classifier_partial_fit N/A N/A N/A N/A N/A classes N/A N/A np unique y N/A data N/A X X_csr N/A N/A clf N/A PassiveAggressiveClassifier C 1.0 fit_intercept True random_state 0 N/A t N/A range 30 N/A N/A N/A N/A clf partial_fit data y classes N/A score N/A N/A clf score data y N/A N/A assert_greater score 0.79 N/A test_classifier_refit N/A N/A N/A N/A N/A clf N/A N/A N/A PassiveAggressiveClassifier fit X y N/A N/A assert_array_equal N/A clf classes_ N/A N/A np unique y N/A N/A N/A clf fit N/A X N/A N/A N/A -1 N/A N/A iris target_names N/A y N/A N/A assert_array_equal N/A clf classes_ N/A iris target_names N/A test_classifier_correctness N/A N/A N/A N/A N/A y_bin N/A N/A y copy N/A N/A y_bin N/A N/A y 1 -1 N/A loss N/A hinge squared_hinge N/A N/A clf1 N/A MyPassiveAggressive C 1.0 loss loss fit_intercept True n_iter 2 N/A N/A N/A clf1 fit X y_bin N/A data N/A X X_csr N/A N/A clf2 N/A PassiveAggressiveClassifier C 1.0 loss loss fit_intercept True n_iter 2 shuffle False N/A N/A N/A clf2 fit data y_bin N/A N/A assert_array_almost_equal N/A clf1 w N/A N/A N/A clf2 coef_ ravel decimal 2 N/A test_classifier_undefined_methods N/A N/A N/A N/A N/A clf N/A PassiveAggressiveClassifier N/A meth N/A predict_proba predict_log_proba transform N/A N/A N/A assert_raises AttributeError N/A N/A N/A x N/A N/A getattr clf x meth N/A test_class_weights N/A N/A N/A N/A N/A X2 N/A N/A np array N/A N/A -1.0 -1.0 N/A -1.0 0 N/A -0.8 -1.0 N/A 1.0 1.0 N/A 1.0 0.0 N/A y2 N/A 1 1 1 -1 -1 N/A clf N/A PassiveAggressiveClassifier C 0.1 n_iter 100 class_weight None random_state 100 N/A N/A N/A clf fit X2 y2 N/A N/A assert_array_equal N/A N/A clf predict N/A N/A 0.2 -1.0 N/A N/A np array N/A 1 N/A clf N/A PassiveAggressiveClassifier C 0.1 n_iter 100 class_weight N/A 1 0.001 random_state 100 N/A N/A N/A clf fit X2 y2 N/A N/A assert_array_equal N/A N/A clf predict N/A N/A 0.2 -1.0 N/A N/A np array N/A -1 N/A test_partial_fit_weight_class_balanced N/A N/A N/A N/A N/A clf N/A PassiveAggressiveClassifier class_weight balanced N/A N/A assert_raises ValueError N/A clf partial_fit X y classes N/A N/A np unique y N/A test_equal_class_weight N/A N/A N/A N/A N/A X2 N/A N/A 1 0 N/A 1 0 N/A 0 1 N/A 0 1 N/A y2 N/A 0 0 1 1 N/A clf N/A PassiveAggressiveClassifier C 0.1 n_iter 1000 class_weight None N/A N/A N/A clf fit X2 y2 N/A clf_balanced N/A PassiveAggressiveClassifier C 0.1 n_iter 1000 class_weight balanced N/A N/A N/A clf_balanced fit X2 y2 N/A clf_weighted N/A PassiveAggressiveClassifier C 0.1 n_iter 1000 class_weight N/A 0 1 0.5 0.5 N/A N/A N/A clf_weighted fit X2 y2 N/A N/A assert_almost_equal N/A clf coef_ N/A clf_weighted coef_ decimal 2 N/A N/A assert_almost_equal N/A clf coef_ N/A clf_balanced coef_ decimal 2 N/A test_wrong_class_weight_label N/A N/A N/A N/A N/A X2 N/A N/A np array N/A N/A -1.0 -1.0 N/A -1.0 0 N/A -0.8 -1.0 N/A 1.0 1.0 N/A 1.0 0.0 N/A y2 N/A 1 1 1 -1 -1 N/A clf N/A PassiveAggressiveClassifier class_weight N/A 0 0.5 N/A N/A assert_raises ValueError N/A clf fit X2 y2 N/A test_wrong_class_weight_format N/A N/A N/A N/A N/A X2 N/A N/A np array N/A N/A -1.0 -1.0 N/A -1.0 0 N/A -0.8 -1.0 N/A 1.0 1.0 N/A 1.0 0.0 N/A y2 N/A 1 1 1 -1 -1 N/A clf N/A PassiveAggressiveClassifier class_weight N/A 0.5 N/A N/A assert_raises ValueError N/A clf fit X2 y2 N/A clf N/A PassiveAggressiveClassifier class_weight the larch N/A N/A assert_raises ValueError N/A clf fit X2 y2 N/A test_regressor_mse N/A N/A N/A N/A N/A y_bin N/A N/A y copy N/A N/A y_bin N/A N/A y 1 -1 N/A data N/A X X_csr N/A N/A fit_intercept N/A True False N/A N/A reg N/A PassiveAggressiveRegressor C 1.0 n_iter 50 fit_intercept fit_intercept random_state 0 N/A N/A N/A reg fit data y_bin N/A pred N/A N/A reg predict data N/A N/A assert_less N/A N/A np mean N/A N/A pred y_bin 2 1.7 N/A test_regressor_partial_fit N/A N/A N/A N/A N/A y_bin N/A N/A y copy N/A N/A y_bin N/A N/A y 1 -1 N/A data N/A X X_csr N/A N/A reg N/A PassiveAggressiveRegressor C 1.0 fit_intercept True random_state 0 N/A t N/A range 50 N/A N/A N/A N/A reg partial_fit data y_bin N/A pred N/A N/A reg predict data N/A N/A assert_less N/A N/A np mean N/A N/A pred y_bin 2 1.7 N/A test_regressor_correctness N/A N/A N/A N/A N/A y_bin N/A N/A y copy N/A N/A y_bin N/A N/A y 1 -1 N/A loss N/A epsilon_insensitive squared_epsilon_insensitive N/A N/A reg1 N/A MyPassiveAggressive C 1.0 loss loss fit_intercept True n_iter 2 N/A N/A N/A reg1 fit X y_bin N/A data N/A X X_csr N/A N/A reg2 N/A PassiveAggressiveRegressor C 1.0 loss loss fit_intercept True n_iter 2 shuffle False N/A N/A N/A reg2 fit data y_bin N/A N/A assert_array_almost_equal N/A reg1 w N/A N/A N/A reg2 coef_ ravel decimal 2 N/A test_regressor_undefined_methods N/A N/A N/A N/A N/A reg N/A PassiveAggressiveRegressor N/A meth N/A transform N/A N/A N/A assert_raises AttributeError N/A N/A N/A x N/A N/A getattr reg x meth N/A