tdlm_train.py 文件源码

python
阅读 30 收藏 0 点赞 0 评论 0

项目:topically-driven-language-model 作者: jhlau 项目源码 文件源码
def print_progress(bi, batch_total, is_training, output_string):
    if (((bi % 10) == 0) and cf.verbose) or (bi == batch_total-1):
        if is_training:
            sys.stdout.write("TRAIN ")
        else:
            sys.stdout.write("VALID ")
        sys.stdout.write(output_string)
        if bi == (batch_total-1):
            sys.stdout.write("\n")
        else:
            sys.stdout.write("\r")
        sys.stdout.flush()
######
#main#
######
#set the seeds
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号