Module Import alias Import alias Import alias Import alias identifier Import alias ImportFrom alias ImportFrom alias Import alias identifier ImportFrom alias ImportFrom alias alias ImportFrom alias ImportFrom alias Assign NameStore Call NameLoad Assign NameStore AttributeLoad NameLoad attr ClassDef bases AttributeLoad NameLoad attr body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Delete AttributeDel NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad keyword NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Str Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad keyword NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore BinOpMult ListLoad Num Num Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr CompareLtE SubscriptLoad AttributeLoad NameLoad attr Index Num Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Num SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad keyword AttributeLoad NameLoad attr keyword AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Expr Call AttributeLoad NameLoad attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str keyword Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr ListLoad Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr ListLoad Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr ListLoad Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad AttributeLoad NameLoad attr Index Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Expr Call AttributeLoad NameLoad attr ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num Num Num Num Num Num Num Expr Call AttributeLoad NameLoad attr ListComp Call NameLoad AttributeLoad NameLoad attr Num comprehension NameStore AttributeLoad NameLoad attr ListLoad Num decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr keyword Num keyword Num keyword Num keyword Num keyword Num keyword AttributeLoad NameLoad attr Assign NameStore BinOpAdd BinOpMult Num Num Num Assign NameStore BinOpAdd NameLoad Call AttributeLoad NameLoad attr keyword NameLoad Assign NameStore Call NameLoad keyword NameLoad keyword NameLoad keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad NameLoad Slice Num Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad keyword AttributeLoad NameLoad attr Assign NameStore Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore Call NameLoad keyword NameLoad keyword Call AttributeLoad NameLoad attr keyword BinOpAdd AttributeLoad NameLoad attr NameLoad keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign NameStore BinOpMult NameLoad Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Num NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Num NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Num NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Num NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareIn AttributeLoad NameLoad attr ListLoad Num Num Num Num body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num orelse If CompareNotEq AttributeLoad NameLoad attr Num body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num orelse If Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num orelse Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body If CompareEq NameLoad Num body Assign NameStore Num orelse Assign NameStore BinOpSub NameLoad Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body If CompareGt NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad Num orelse Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad BinOpSub NameLoad BinOpSub NameLoad Num Call AttributeLoad Str attr keyword NameLoad keyword NameLoad keyword NameLoad keyword AttributeLoad SubscriptLoad NameLoad Index Num attr keyword Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad SubscriptLoad NameLoad Index Num attr attr Expr Call AttributeLoad NameLoad attr AttributeLoad SubscriptLoad NameLoad Index Num attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign SubscriptStore AttributeLoad NameLoad attr Slice Num AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword NameLoad keyword AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str decorator_list decorator_list
N/A N/A unittest N/A datetime N/A calendar N/A numpy np N/A pytz itertools chain six itervalues N/A zipline.finance.risk risk zipline.utils factory zipline.finance.trading SimulationParameters TradingEnvironment N/A answer_key answer_key AnswerKey N/A ANSWER_KEY N/A AnswerKey N/A RETURNS N/A ANSWER_KEY RETURNS TestRisk N/A N/A unittest TestCase N/A setUpClass N/A N/A cls N/A N/A N/A N/A cls env N/A TradingEnvironment N/A classmethod tearDownClass N/A N/A cls N/A N/A N/A N/A cls env N/A classmethod setUp N/A N/A self N/A N/A N/A start_date N/A N/A datetime datetime year 2006 month 1 day 1 hour 0 minute 0 tzinfo N/A pytz utc N/A end_date N/A N/A datetime datetime year 2006 month 12 day 31 tzinfo N/A pytz utc N/A N/A self sim_params N/A SimulationParameters period_start start_date period_end end_date env N/A self env N/A N/A self algo_returns_06 N/A N/A factory create_returns_from_list RETURNS N/A self sim_params N/A N/A self benchmark_returns_06 N/A N/A answer_key RETURNS_DATA N/A Benchmark Returns N/A N/A self metrics_06 N/A N/A risk RiskReport N/A self algo_returns_06 N/A self sim_params benchmark_returns N/A self benchmark_returns_06 env N/A self env N/A start_08 N/A N/A datetime datetime year 2008 month 1 day 1 hour 0 minute 0 tzinfo N/A pytz utc N/A end_08 N/A N/A datetime datetime year 2008 month 12 day 31 tzinfo N/A pytz utc N/A N/A self sim_params08 N/A SimulationParameters period_start start_08 period_end end_08 env N/A self env N/A tearDown N/A N/A self N/A N/A N/A N/A test_factory N/A N/A self N/A N/A N/A returns N/A N/A 0.1 100 N/A r_objects N/A N/A factory create_returns_from_list returns N/A self sim_params N/A N/A N/A self assertTrue N/A N/A N/A r_objects index N/A -1 N/A N/A datetime datetime year 2006 month 12 day 31 tzinfo N/A pytz utc N/A test_drawdown N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_list N/A 1.0 -0.5 0.8 0.17 1.0 -0.1 -0.45 N/A self sim_params N/A metrics N/A N/A risk RiskMetricsPeriod N/A N/A returns index N/A 0 N/A N/A returns index N/A -1 returns env N/A self env benchmark_returns N/A N/A self env benchmark_returns N/A N/A N/A self assertEqual N/A metrics max_drawdown 0.505 N/A test_benchmark_returns_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_period_returns N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_RETURNS N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_period_returns N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_RETURNS N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_period_returns N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_RETURNS N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_period_returns N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_RETURNS N/A year N/A test_trading_days_06 N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_range N/A self sim_params N/A metrics N/A N/A risk RiskReport returns N/A self sim_params env N/A self env N/A N/A N/A self assertEqual N/A N/A x num_trading_days N/A x N/A metrics year_periods N/A 251 N/A N/A N/A self assertEqual N/A N/A x num_trading_days N/A x N/A metrics month_periods N/A 20 19 23 19 22 22 20 23 20 22 21 20 N/A test_benchmark_volatility_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_volatility N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_VOLATILITY N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_volatility N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_VOLATILITY N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_volatility N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_VOLATILITY N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_volatility N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY BENCHMARK_PERIOD_VOLATILITY N/A year N/A test_algorithm_returns_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_period_returns N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_RETURNS N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_period_returns N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_RETURNS N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_period_returns N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_RETURNS N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_period_returns N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_RETURNS N/A year N/A test_algorithm_volatility_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_volatility N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_VOLATILITY N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_volatility N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_VOLATILITY N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_volatility N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_VOLATILITY N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_volatility N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_VOLATILITY N/A year N/A test_algorithm_sharpe_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sharpe N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SHARPE N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sharpe N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SHARPE N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sharpe N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SHARPE N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sharpe N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SHARPE N/A year N/A test_algorithm_downside_risk_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x downside_risk N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_DOWNSIDE_RISK N/A Monthly decimal 4 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x downside_risk N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_DOWNSIDE_RISK N/A 3-Month decimal 4 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x downside_risk N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_DOWNSIDE_RISK N/A 6-month decimal 4 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x downside_risk N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_DOWNSIDE_RISK N/A year decimal 4 N/A test_algorithm_sortino_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sortino N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SORTINO N/A Monthly decimal 3 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sortino N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SORTINO N/A 3-Month decimal 3 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sortino N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SORTINO N/A 6-month decimal 3 N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x sortino N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_SORTINO N/A year decimal 3 N/A test_algorithm_information_06 N/A N/A self N/A N/A N/A N/A N/A self assertEqual N/A N/A round N/A x information 3 N/A x N/A N/A self metrics_06 month_periods N/A 0.131 -0.11 -0.067 0.136 0.301 -0.387 0.107 -0.032 -0.058 0.069 0.095 -0.123 N/A N/A N/A self assertEqual N/A N/A round N/A x information 3 N/A x N/A N/A self metrics_06 three_month_periods N/A -0.013 -0.009 0.111 -0.014 -0.017 -0.108 0.011 -0.004 0.032 0.011 N/A N/A N/A self assertEqual N/A N/A round N/A x information 3 N/A x N/A N/A self metrics_06 six_month_periods N/A -0.013 -0.014 -0.003 -0.002 -0.011 -0.041 0.011 N/A N/A N/A self assertEqual N/A N/A round N/A x information 3 N/A x N/A N/A self metrics_06 year_periods N/A -0.001 N/A test_algorithm_beta_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x beta N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BETA N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x beta N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BETA N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x beta N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BETA N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x beta N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BETA N/A year N/A test_algorithm_alpha_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x alpha N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_ALPHA N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x alpha N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_ALPHA N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x alpha N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_ALPHA N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x alpha N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_ALPHA N/A year N/A test_algorithm_covariance_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_covariance N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_COVARIANCE N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_covariance N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_COVARIANCE N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_covariance N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_COVARIANCE N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x algorithm_covariance N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_COVARIANCE N/A year N/A test_benchmark_variance_06 N/A N/A self N/A N/A N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_variance N/A x N/A N/A self metrics_06 month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BENCHMARK_VARIANCE N/A Monthly N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_variance N/A x N/A N/A self metrics_06 three_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BENCHMARK_VARIANCE N/A 3-Month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_variance N/A x N/A N/A self metrics_06 six_month_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BENCHMARK_VARIANCE N/A 6-month N/A N/A N/A N/A np testing assert_almost_equal N/A N/A x benchmark_variance N/A x N/A N/A self metrics_06 year_periods N/A N/A ANSWER_KEY ALGORITHM_PERIOD_BENCHMARK_VARIANCE N/A year N/A test_benchmark_returns_08 N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_range N/A self sim_params08 N/A metrics N/A N/A risk RiskReport returns N/A self sim_params08 env N/A self env N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_period_returns 3 N/A x N/A metrics month_periods N/A -0.061 -0.035 -0.006 0.048 0.011 -0.086 -0.01 0.012 -0.091 -0.169 -0.075 0.008 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_period_returns 3 N/A x N/A metrics three_month_periods N/A -0.099 0.005 0.052 -0.032 -0.085 -0.084 -0.089 -0.236 -0.301 -0.226 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_period_returns 3 N/A x N/A metrics six_month_periods N/A -0.128 -0.081 -0.036 -0.118 -0.301 -0.36 -0.294 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_period_returns 3 N/A x N/A metrics year_periods N/A -0.385 N/A test_trading_days_08 N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_range N/A self sim_params08 N/A metrics N/A N/A risk RiskReport returns N/A self sim_params08 env N/A self env N/A N/A N/A self assertEqual N/A N/A x num_trading_days N/A x N/A metrics year_periods N/A 253 N/A N/A N/A self assertEqual N/A N/A x num_trading_days N/A x N/A metrics month_periods N/A 21 20 20 22 21 21 22 21 21 23 19 22 N/A test_benchmark_volatility_08 N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_range N/A self sim_params08 N/A metrics N/A N/A risk RiskReport returns N/A self sim_params08 env N/A self env N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_volatility 3 N/A x N/A metrics month_periods N/A 0.07 0.058 0.082 0.054 0.041 0.057 0.068 0.06 0.157 0.244 0.195 0.145 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_volatility 3 N/A x N/A metrics three_month_periods N/A 0.12 0.113 0.105 0.09 0.098 0.107 0.179 0.293 0.344 0.34 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_volatility 3 N/A x N/A metrics six_month_periods N/A 0.15 0.149 0.15 0.2 0.308 0.36 0.383 N/A N/A N/A self assertEqual N/A N/A round N/A x benchmark_volatility 3 N/A x N/A metrics year_periods N/A 0.411 N/A test_treasury_returns_06 N/A N/A self N/A N/A N/A returns N/A N/A factory create_returns_from_range N/A self sim_params N/A metrics N/A N/A risk RiskReport returns N/A self sim_params env N/A self env N/A N/A N/A self assertEqual N/A N/A round N/A x treasury_period_return 4 N/A x N/A metrics month_periods N/A 0.0037 0.0034 0.0039 0.0038 0.004 0.0037 0.0043 0.0043 0.0038 0.0044 0.0043 0.004 N/A N/A N/A self assertEqual N/A N/A round N/A x treasury_period_return 4 N/A x N/A metrics three_month_periods N/A 0.0114 0.0116 0.0122 0.0125 0.0129 0.0127 0.0123 0.0128 0.0125 0.0127 N/A N/A N/A self assertEqual N/A N/A round N/A x treasury_period_return 4 N/A x N/A metrics six_month_periods N/A 0.026 0.0257 0.0258 0.0252 0.0259 0.0256 0.0257 N/A N/A N/A self assertEqual N/A N/A round N/A x treasury_period_return 4 N/A x N/A metrics year_periods N/A 0.05 N/A test_benchmarkrange N/A N/A self N/A N/A N/A N/A N/A self check_year_range N/A N/A datetime datetime year 2008 month 1 day 1 tzinfo N/A pytz utc 2 N/A test_partial_month N/A N/A self N/A N/A N/A start N/A N/A datetime datetime year 1991 month 1 day 1 hour 0 minute 0 tzinfo N/A pytz utc N/A total_days N/A N/A 365 5 2 N/A end N/A start N/A N/A datetime timedelta days total_days N/A sim_params90s N/A SimulationParameters period_start start period_end end env N/A self env N/A returns N/A N/A factory create_returns_from_range sim_params90s N/A returns N/A returns N/A -10 N/A metrics N/A N/A risk RiskReport returns sim_params90s env N/A self env N/A total_months 60 N/A N/A N/A self check_metrics metrics total_months start N/A check_year_range N/A N/A self start_date years N/A N/A N/A sim_params N/A SimulationParameters period_start start_date period_end N/A N/A start_date replace year N/A N/A start_date year years env N/A self env N/A returns N/A N/A factory create_returns_from_range sim_params N/A metrics N/A N/A risk RiskReport returns N/A self sim_params env N/A self env N/A total_months N/A years 12 N/A N/A N/A self check_metrics metrics total_months start_date N/A check_metrics N/A N/A self metrics total_months start_date N/A N/A N/A 
        confirm that the right number of riskmetrics were calculated for each
        window length.
         N/A N/A N/A self assert_range_length N/A metrics month_periods total_months 1 start_date N/A N/A N/A self assert_range_length N/A metrics three_month_periods total_months 3 start_date N/A N/A N/A self assert_range_length N/A metrics six_month_periods total_months 6 start_date N/A N/A N/A self assert_range_length N/A metrics year_periods total_months 12 start_date N/A assert_last_day N/A N/A self period_end N/A N/A N/A N/A N/A period_end month N/A 9 4 6 11 N/A N/A N/A N/A self assertEqual N/A period_end day 30 N/A N/A N/A N/A period_end month 2 N/A N/A N/A N/A self assertEqual N/A period_end day 31 N/A N/A N/A N/A calendar isleap N/A period_end year N/A N/A N/A N/A self assertEqual N/A period_end day 29 N/A N/A N/A N/A self assertEqual N/A period_end day 28 N/A assert_month N/A N/A self start_month actual_end_month N/A N/A N/A N/A start_month 1 N/A N/A expected_end_month 12 N/A N/A expected_end_month N/A start_month 1 N/A N/A N/A self assertEqual expected_end_month actual_end_month N/A assert_range_length N/A N/A self col total_months period_length start_date N/A N/A N/A N/A period_length total_months N/A N/A N/A N/A self assertEqual N/A len col 0 N/A N/A N/A N/A self assertEqual N/A len col N/A total_months N/A period_length 1 N/A N/A mismatch for total months -                 expected:{total_months}/actual:{actual},                 period:{period_length}, start:{start_date},                 calculated end:{end} format total_months total_months period_length period_length start_date start_date end N/A N/A col N/A -1 end_date actual N/A len col N/A N/A N/A self assert_month N/A start_date month N/A N/A N/A col N/A -1 end_date month N/A N/A N/A self assert_last_day N/A N/A col N/A -1 end_date N/A test_sparse_benchmark N/A N/A self N/A N/A N/A benchmark_returns N/A N/A N/A self benchmark_returns_06 copy N/A N/A N/A benchmark_returns iloc N/A 2 N/A np nan N/A report N/A N/A risk RiskReport N/A self algo_returns_06 N/A self sim_params benchmark_returns benchmark_returns env N/A self env N/A risk_period N/A N/A chain from_iterable N/A itervalues N/A N/A report to_dict N/A N/A N/A N/A self assertIsNone N/A risk_period N/A beta N/A N/A