Module Expr Str Import alias Import alias Import alias Import alias ImportFrom alias alias alias alias alias alias alias Import alias identifier Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Str Assign NameStore Str ClassDef bases body FunctionDef arguments args NameParam defaults body Assign NameStore Num Assign NameStore Call AttributeLoad NameLoad attr BinOpMod Str NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Num Assign NameStore Call AttributeLoad NameLoad attr BinOpMod Str NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Num Assign NameStore ListLoad BinOpMod Str NameLoad BinOpMod Str NameLoad Str For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Num Assign NameStore Num Assign NameStore BinOpMod Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Num decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad TryExcept body Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad Num Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Num handlers ExceptHandler type NameLoad body Pass Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad NameLoad AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad decorator_list decorator_list ClassDef bases body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Expr Call NameLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call NameLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call NameLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call NameLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad decorator_list decorator_list ClassDef bases body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad AttributeLoad NameLoad attr Str NameStore body Expr Call AttributeLoad NameLoad attr Str decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call NameLoad NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call NameLoad NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call NameLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str decorator_list decorator_list ClassDef bases body FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Str With Call NameLoad NameLoad Str NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad Str Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad Str BinOpAdd Str AttributeLoad NameLoad attr Expr Call NameLoad Call AttributeLoad NameLoad attr NameLoad Str BinOpAdd Str AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A 
Created on Oct 1, 2015

@author: kashefy
 N/A os N/A sys N/A shutil N/A tempfile nose.tools assert_equal assert_false assert_raises assert_is_instance assert_is_none assert_less assert_true N/A log_utils lu N/A CURRENT_MODULE_PATH N/A N/A N/A os path abspath N/A N/A N/A sys modules N/A __name__ __file__ N/A ROOT_PKG_PATH N/A N/A N/A os path dirname CURRENT_MODULE_PATH N/A TEST_DATA_DIRNAME test_data N/A TEST_LOG_FILENAME caffe.hostname.username.log.INFO.20150917-163712.31405 TestPID N/A N/A test_pid_from_str N/A N/A self N/A N/A N/A n 26943 N/A res N/A N/A lu pid_from_str N/A %s n N/A N/A assert_is_instance res int N/A N/A assert_equal res n N/A test_pid_from_str_neg N/A N/A self N/A N/A N/A n -26943 N/A res N/A N/A lu pid_from_str N/A %s n N/A N/A assert_is_instance res int N/A N/A assert_equal res n N/A test_pid_from_str_invalid_alpha N/A N/A self N/A N/A N/A n 26943 N/A x N/A N/A a%s n N/A %sa n 269a43 N/A s x N/A N/A res N/A N/A lu pid_from_str s N/A N/A assert_is_instance res int N/A N/A assert_equal res -1 N/A test_pid_from_logname N/A N/A self N/A N/A N/A s caffe.host.user.log.INFO.20151001-132750.26943 N/A res N/A N/A lu pid_from_logname s N/A N/A assert_is_instance res int N/A N/A assert_equal res 26943 N/A n 77775 N/A s N/A log.%s n N/A res N/A N/A lu pid_from_logname s N/A N/A assert_is_instance res int N/A N/A assert_equal res n N/A test_pid_from_logname_invalid N/A N/A self N/A N/A N/A s caffe.host.user.log.INFO.20151001-132750.26943.txt N/A res N/A N/A lu pid_from_logname s N/A N/A assert_is_instance res int N/A N/A assert_equal res -1 N/A test_read_pid N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A N/A N/A os path dirname ROOT_PKG_PATH TEST_DATA_DIRNAME TEST_LOG_FILENAME N/A result N/A N/A lu read_pid fpath N/A N/A assert_is_instance result int N/A N/A assert_equal result 31405 N/A test_read_pid_from_content N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A N/A N/A os path dirname ROOT_PKG_PATH TEST_DATA_DIRNAME TEST_LOG_FILENAME N/A path_temp_dir N/A N/A tempfile mkdtemp N/A fpath2 N/A N/A N/A os path join path_temp_dir foo.txt N/A N/A N/A shutil copyfile fpath fpath2 N/A N/A N/A N/A assert_less N/A N/A lu pid_from_logname fpath2 0 N/A result N/A N/A lu read_pid fpath2 N/A N/A assert_is_instance result int N/A N/A assert_equal result 31405 N/A N/A N/A Exception N/A N/A N/A N/A N/A shutil rmtree path_temp_dir N/A test_read_pid_invalid N/A N/A self N/A N/A N/A path_temp_dir N/A N/A tempfile mkdtemp N/A fpath N/A N/A N/A os path join path_temp_dir TEST_LOG_FILENAME N/A N/A open fpath w f N/A N/A N/A N/A f write log file N/A N/A assert_true N/A N/A lu is_caffe_info_log fpath N/A fpath2 N/A N/A N/A os path join path_temp_dir foo.txt N/A N/A N/A shutil copyfile fpath fpath2 N/A N/A assert_raises IOError N/A lu read_pid fpath2 N/A N/A N/A shutil rmtree path_temp_dir N/A N/A TestCaffeLog N/A N/A setup_class N/A N/A self N/A N/A N/A N/A self dir_tmp N/A N/A tempfile mkdtemp N/A N/A self path_real_log N/A N/A N/A os path join N/A N/A N/A os path dirname ROOT_PKG_PATH TEST_DATA_DIRNAME TEST_LOG_FILENAME N/A classmethod teardown_class N/A N/A self N/A N/A N/A N/A N/A shutil rmtree N/A self dir_tmp N/A classmethod test_is_caffe_log_invalid_dir N/A N/A self N/A N/A N/A N/A assert_true N/A N/A N/A os path isdir N/A self dir_tmp N/A N/A assert_false N/A N/A lu is_caffe_log N/A self dir_tmp N/A test_is_caffe_log N/A N/A self N/A N/A N/A N/A assert_true N/A N/A lu is_caffe_log N/A self path_real_log N/A test_is_caffe_log_invalid_prefix N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A self dir_tmp foo.hostname.username.log.INFO.20150917-163712.31405 N/A N/A open fpath w f N/A N/A N/A N/A f write log file N/A N/A assert_false N/A N/A lu is_caffe_log fpath N/A test_is_caffe_log_invalid_content N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A self dir_tmp caffe.hostname.username.log.INFO.20150917-163712.31405 N/A N/A open fpath w f N/A N/A N/A N/A f write foo N/A N/A assert_false N/A N/A lu is_caffe_log fpath N/A test_is_caffe_info_log N/A N/A self N/A N/A N/A N/A assert_true N/A N/A lu is_caffe_log N/A self path_real_log N/A test_is_caffe_info_log_invalid_fname N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A self dir_tmp foo.hostname.username.log.ERROR.20150917-163712.31405 N/A N/A open fpath w f N/A N/A N/A N/A f write log file N/A N/A assert_false N/A N/A lu is_caffe_info_log fpath N/A test_is_complete N/A N/A self N/A N/A N/A N/A assert_true N/A N/A lu is_complete N/A self path_real_log N/A fpath N/A N/A N/A os path join N/A self dir_tmp foo.hostname.username.log.ERROR.20150917-163712.31405 N/A N/A open fpath w f N/A N/A N/A N/A f write log file N/A N/A assert_false N/A N/A lu is_complete fpath N/A N/A TestReadMeUtils N/A N/A setup_class N/A N/A self N/A N/A N/A N/A self dir_tmp N/A N/A tempfile mkdtemp N/A N/A self path_real_log N/A N/A N/A os path join N/A N/A N/A os path dirname ROOT_PKG_PATH TEST_DATA_DIRNAME TEST_LOG_FILENAME N/A N/A N/A shutil copyfile N/A self path_real_log N/A N/A N/A os path join N/A self dir_tmp TEST_LOG_FILENAME N/A N/A self path_real_log N/A N/A N/A os path join N/A self dir_tmp TEST_LOG_FILENAME N/A N/A self path_readme N/A N/A N/A os path join N/A self dir_tmp readme.txt N/A N/A open N/A self path_readme w f N/A N/A N/A N/A f write foo N/A classmethod teardown_class N/A N/A self N/A N/A N/A N/A N/A shutil rmtree N/A self dir_tmp N/A classmethod test_get_rel_readme_path_from_dir N/A N/A self N/A N/A N/A p N/A N/A lu get_rel_readme_path N/A self dir_tmp N/A N/A assert_equal p N/A self path_readme N/A test_get_rel_readme_path_from_log N/A N/A self N/A N/A N/A p N/A N/A lu get_rel_readme_path N/A self path_real_log N/A N/A assert_equal p N/A self path_readme N/A test_readme_to_str N/A N/A self N/A N/A N/A N/A assert_equal N/A N/A lu readme_to_str N/A self path_readme foo N/A N/A TestFindLine N/A N/A setup_class N/A N/A self N/A N/A N/A N/A self dir_tmp N/A N/A tempfile mkdtemp N/A classmethod teardown_class N/A N/A self N/A N/A N/A N/A N/A shutil rmtree N/A self dir_tmp N/A classmethod test_find_line N/A N/A self N/A N/A N/A fpath N/A N/A N/A os path join N/A self dir_tmp foo.txt N/A N/A open fpath w f N/A N/A N/A N/A f write line one
 N/A N/A N/A f write line two
 N/A N/A N/A f write LINE x
 N/A N/A N/A f write line y
 N/A N/A N/A f write last line
 N/A N/A assert_is_none N/A N/A lu find_line fpath hello N/A N/A assert_equal N/A N/A lu find_line fpath line N/A line one N/A os linesep N/A N/A assert_equal N/A N/A lu find_line fpath LINE N/A LINE x N/A os linesep N/A N/A