def set_schedule():
    # schedule.every().day.at('01:00').do(run_threaded, update_author)
    schedule.every().day.at('07:00').do(run_threaded, update_video)
    schedule.every().day.at('12:00').do(run_threaded,
                                        FansWatcher().watchBigAuthor)
    # schedule.every().day.at('13:00').do(run_threaded, author_fans_rate_caculate)
    schedule.every().day.at('14:00').do(run_threaded, auto_add_author)
    # schedule.every().day.at('16:50').do(run_threaded, auto_crawl_bangumi)
    schedule.every().day.at('22:00').do(run_threaded, auto_add_video)
    # schedule.every().day.at('04:00').do(run_threaded, add_tag_task)

    schedule.every().wednesday.at('03:20').do(run_threaded,
                                              compute_video_rank_table)
    schedule.every().monday.at('03:20').do(run_threaded, calculate_author_rank)

    schedule.every().thursday.at('15:20').do(run_threaded,
                                             KeywordAdder().add_omitted)

    schedule.every().week.do(run_threaded, update_unfocus_video)
    schedule.every().hour.do(run_threaded, sendSiteInfoCrawlRequest)
    schedule.every(1).minutes.do(run_threaded, crawlOnlineTopListData)
    schedule.every(15).minutes.do(run_threaded, gen_online)
Example #2
0

def run_threaded(job_func):
    job_thread = threading.Thread(target=job_func)
    job_thread.start()


if __name__ == "__main__":
    schedule.every().day.at('01:00').do(run_threaded, update_author)
    schedule.every().day.at('07:00').do(run_threaded, update_video)
    schedule.every().day.at('12:00').do(run_threaded,
                                        FansWatcher().watchBigAuthor)
    schedule.every().day.at('13:00').do(run_threaded,
                                        author_fans_rate_caculate)
    schedule.every().day.at('14:00').do(run_threaded, auto_add_author)
    schedule.every().day.at('16:50').do(run_threaded, auto_crawl_bangumi)
    schedule.every().day.at('22:00').do(run_threaded, auto_add_video)
    schedule.every().day.at('04:00').do(run_threaded, add_tag_task)

    schedule.every().wednesday.at('03:20').do(run_threaded,
                                              compute_video_rank_table)
    schedule.every().monday.at('03:20').do(run_threaded, calculate_author_rank)

    schedule.every().thursday.at('15:20').do(run_threaded,
                                             KeywordAdder().add_omitted)

    schedule.every().week.do(run_threaded, update_unfocus_video)
    schedule.every().hour.do(run_threaded, sendSiteInfoCrawlRequest)
    schedule.every(1).minutes.do(run_threaded, crawlOnlineTopListData)
    schedule.every(15).minutes.do(run_threaded, gen_online)
Example #3
0
from biliob_analyzer.author_analyzer import AuthorAnalyzer
from biliob_analyzer.video_analyzer import VideoAnalyzer
# import biliob_analyzer.author_rate_caculate
import biliob_analyzer.author_fans_watcher
# import biliob_analyzer.author_rank
# import biliob_analyzer.video_rank
from biliob_analyzer.add_keyword import KeywordAdder

kwAdder = KeywordAdder()
kwAdder.add_all_author()
kwAdder.add_all_video()
# kwAdder.add_omitted()

author_analyzer = AuthorAnalyzer()
video_analyzer = VideoAnalyzer()

author_analyzer.author_filter()
video_analyzer.video_filter()