def get_default_sess_config(mem_fraction=0.9):
    conf = tf.ConfigProto()
    conf.gpu_options.per_process_gpu_memory_fraction = mem_fraction
    conf.gpu_options.allocator_type = 'BFC'
    conf.allow_soft_placement = True
    #conf.log_device_placement = True
    return conf
Return a better session config to use as default.
dataset/ETHPy150Open ppwwyyxx/tensorpack/tensorpack/tfutils/common.py/get_default_sess_config