Module Import alias identifier ImportFrom alias alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias alias alias ImportFrom alias ImportFrom alias alias ImportFrom alias FunctionDef arguments args defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index TupleLoad Call AttributeLoad NameLoad attr Num Call AttributeLoad NameLoad attr Num Num Expr Call NameLoad Call NameLoad NameLoad BinOpAdd Call NameLoad NameLoad Num Expr Call NameLoad Call NameLoad NameLoad Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr ListLoad NameLoad ListLoad Num Num Expr Call NameLoad Call NameLoad NameLoad Call NameLoad NameLoad Expr Call NameLoad Call NameLoad SubscriptLoad NameLoad Slice Num BinOpAdd Call NameLoad NameLoad Num decorator_list FunctionDef arguments args defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index TupleLoad Call AttributeLoad NameLoad attr Num Num Call AttributeLoad NameLoad attr Num Expr Call NameLoad Call NameLoad NameLoad BinOpAdd Call NameLoad NameLoad Num Expr Call NameLoad Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr ListLoad NameLoad ListLoad Num Num Expr Call NameLoad Call NameLoad NameLoad Expr Call NameLoad Call NameLoad NameLoad BinOpAdd Call NameLoad NameLoad Num Assign NameStore Call AttributeLoad NameLoad attr ListLoad NameLoad BinOpAdd NameLoad Num Expr Call NameLoad Call NameLoad NameLoad Num Assign NameStore Call AttributeLoad NameLoad attr ListLoad NameLoad BinOpAdd NameLoad Num Expr Call NameLoad Call NameLoad NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr keyword TupleLoad Num Num Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Call AttributeLoad NameLoad attr Expr Call NameLoad Call NameLoad NameLoad TryExcept body ImportFrom alias Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Call AttributeLoad NameLoad attr Expr Call NameLoad Call NameLoad NameLoad Num Expr Call NameLoad Call NameLoad NameLoad handlers ExceptHandler type NameLoad body Pass decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Num Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index TupleLoad Call AttributeLoad NameLoad attr Num Call AttributeLoad NameLoad attr Num Num Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index TupleLoad Call AttributeLoad NameLoad attr Num Num Call AttributeLoad NameLoad attr Num For NameStore Call NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Num For NameStore ListLoad NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body TryExcept body ImportFrom alias handlers ExceptHandler body Raise Call NameLoad Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Num For NameStore Call NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Num Assign NameStore Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Num Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index TupleLoad Call AttributeLoad NameLoad attr Num Call AttributeLoad NameLoad attr Num Num For NameStore Call NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Num Assign NameStore Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body TryExcept body ImportFrom alias handlers ExceptHandler body Raise Call NameLoad Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Num For NameStore Call NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr keyword TupleLoad Num Num Num Assign NameStore Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign TupleStore NameStore NameStore Call NameLoad keyword Num Assign TupleStore NameStore NameStore TupleLoad SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num Assign NameStore Call AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Assign NameStore Call NameLoad keyword Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args defaults body Assign TupleStore NameStore NameStore Call NameLoad keyword Num Assign TupleStore NameStore NameStore TupleLoad SubscriptLoad NameLoad Index Num SubscriptLoad NameLoad Index Num Assign NameStore Call AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num Num Num Num Assign NameStore Call NameLoad keyword Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list
N/A N/A numpy np nose.tools assert_true assert_false nose SkipTest numpy.testing assert_array_equal scipy sparse pystruct.inference.maxprod is_forest inference_max_product iterative_max_product is_chain pystruct.inference inference_ad3 pystruct.datasets generate_blocks generate_blocks_multinomial pystruct.models GridCRF test_is_chain N/A N/A N/A N/A N/A chain N/A N/A np c_ N/A N/A N/A N/A np arange 9 N/A N/A np arange 1 10 N/A N/A assert_true N/A is_chain chain N/A N/A len chain 1 N/A N/A assert_false N/A is_chain chain N/A len chain N/A circle N/A N/A np vstack N/A chain N/A 9 0 N/A N/A assert_false N/A is_chain circle N/A len circle N/A N/A assert_false N/A is_chain N/A chain N/A -1 N/A N/A len chain 1 N/A test_is_forest N/A N/A N/A N/A N/A chain N/A N/A np c_ N/A N/A N/A N/A np arange 1 10 N/A N/A np arange 9 N/A N/A assert_true N/A is_forest chain N/A N/A len chain 1 N/A N/A assert_true N/A is_forest chain N/A circle N/A N/A np vstack N/A chain N/A 9 0 N/A N/A assert_false N/A is_forest circle N/A N/A assert_false N/A is_forest circle N/A N/A len chain 1 N/A two_chains N/A N/A np vstack N/A chain N/A chain 10 N/A N/A assert_true N/A is_forest two_chains 20 N/A disco_graph N/A N/A np vstack N/A chain N/A circle 10 N/A N/A assert_false N/A is_forest disco_graph N/A graph N/A N/A N/A np random uniform size N/A 10 10 N/A edges N/A N/A np c_ N/A N/A N/A graph nonzero N/A N/A assert_false N/A is_forest edges N/A N/A scipy.sparse.csgraph minimum_spanning_tree N/A tree N/A minimum_spanning_tree N/A N/A sparse csr_matrix graph N/A tree_edges N/A N/A np c_ N/A N/A N/A tree nonzero N/A N/A assert_true N/A is_forest tree_edges 10 N/A N/A assert_true N/A is_forest tree_edges N/A N/A N/A ImportError N/A N/A N/A test_tree_max_product_chain N/A N/A N/A N/A N/A rnd N/A N/A N/A np random RandomState 0 N/A forward N/A N/A np c_ N/A N/A N/A N/A np arange 9 N/A N/A np arange 1 10 N/A backward N/A N/A np c_ N/A N/A N/A N/A np arange 1 10 N/A N/A np arange 9 N/A i N/A range 10 N/A N/A unary_potentials N/A N/A rnd normal size N/A 10 3 N/A pairwise_potentials N/A N/A rnd normal size N/A 9 3 3 N/A chain N/A forward backward N/A N/A result_ad3 N/A inference_ad3 unary_potentials pairwise_potentials chain branch_and_bound True N/A result_mp N/A inference_max_product unary_potentials pairwise_potentials chain N/A N/A assert_array_equal result_ad3 result_mp N/A test_tree_max_product_tree N/A N/A N/A N/A N/A N/A scipy.sparse.csgraph minimum_spanning_tree N/A N/A N/A N/A N/A SkipTest Not testing trees, scipy version >= 0.11 required N/A rnd N/A N/A N/A np random RandomState 0 N/A i N/A range 100 N/A N/A graph N/A N/A rnd uniform size N/A 10 10 N/A tree N/A minimum_spanning_tree N/A N/A sparse csr_matrix graph N/A tree_edges N/A N/A np c_ N/A N/A N/A tree nonzero N/A unary_potentials N/A N/A rnd normal size N/A 10 3 N/A pairwise_potentials N/A N/A rnd normal size N/A 9 3 3 N/A result_ad3 N/A inference_ad3 unary_potentials pairwise_potentials tree_edges branch_and_bound True N/A result_mp N/A inference_max_product unary_potentials pairwise_potentials tree_edges N/A N/A assert_array_equal result_ad3 result_mp N/A test_iterative_max_product_chain N/A N/A N/A N/A N/A rnd N/A N/A N/A np random RandomState 0 N/A chain N/A N/A np c_ N/A N/A N/A N/A np arange 9 N/A N/A np arange 1 10 N/A i N/A range 10 N/A N/A unary_potentials N/A N/A rnd normal size N/A 10 3 N/A pairwise_potentials N/A N/A rnd normal size N/A 9 3 3 N/A result_ad3 N/A inference_ad3 unary_potentials pairwise_potentials chain branch_and_bound True N/A result_mp N/A iterative_max_product unary_potentials pairwise_potentials chain N/A N/A assert_array_equal result_ad3 result_mp N/A test_iterative_max_product_tree N/A N/A N/A N/A N/A N/A scipy.sparse.csgraph minimum_spanning_tree N/A N/A N/A N/A N/A SkipTest Not testing trees, scipy version >= 0.11 required N/A rnd N/A N/A N/A np random RandomState 0 N/A i N/A range 100 N/A N/A graph N/A N/A rnd uniform size N/A 10 10 N/A tree N/A minimum_spanning_tree N/A N/A sparse csr_matrix graph N/A tree_edges N/A N/A np c_ N/A N/A N/A tree nonzero N/A unary_potentials N/A N/A rnd normal size N/A 10 3 N/A pairwise_potentials N/A N/A rnd normal size N/A 9 3 3 N/A result_ad3 N/A inference_ad3 unary_potentials pairwise_potentials tree_edges branch_and_bound True N/A result_mp N/A iterative_max_product unary_potentials pairwise_potentials tree_edges N/A N/A assert_array_equal result_ad3 result_mp N/A test_max_product_binary_blocks N/A N/A N/A N/A N/A N/A X Y N/A generate_blocks n_samples 1 N/A N/A x y N/A N/A X N/A 0 N/A Y N/A 0 N/A w N/A N/A np array N/A 1 0 0 1 0 -4 0 N/A crf N/A GridCRF inference_method max-product N/A N/A N/A crf initialize X Y N/A y_hat N/A N/A crf inference x w N/A N/A assert_array_equal y y_hat N/A test_max_product_multinomial_crf N/A N/A N/A N/A N/A N/A X Y N/A generate_blocks_multinomial n_samples 1 N/A N/A x y N/A N/A X N/A 0 N/A Y N/A 0 N/A w N/A N/A np array N/A 1.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 1.0 0.4 -0.3 0.3 -0.5 -0.1 0.3 N/A crf N/A GridCRF inference_method max-product N/A N/A N/A crf initialize X Y N/A y_hat N/A N/A crf inference x w N/A N/A assert_array_equal y y_hat N/A