codecamp

TensorFlow变量:tf.min_max_variable_partitioner

tf.min_max_variable_partitioner 函数
min_max_variable_partitioner(
    max_partitions=1,
    axis=0,
    min_slice_size=256 << 10,
    bytes_per_string_element=16
)

定义在:tensorflow/python/ops/partitioned_variables.py.

参见指南:变量>切分变量分区

分区为每个切片分配最小尺寸.
返回一个分区,该值对给定形状的变量和 dtype 进行分区,这样每个分区都有最小的 min_slice_size 切片的变量.此类分区的最大数目 (上限) 由 max_partitions 提供.

参数:

  • max_partitions:分区数的上限,默认为 1.
  • axis:沿其对变量进行分区的轴,默认为 0.
  • min_slice_size:每个分区的可变切片的最小尺寸,默认为 256K.
  • bytes_per_string_element:如果变量是 string 类型的,这将提供一个估计变量中每个标量的大小.

返回值:

可用作variable_scopeget_variable, 和 get_partitioned_variable_list分区参数的分区函数.


TensorFlow数学函数:tf.minimum
multinomial函数:从多项式分布中抽取样本
温馨提示
下载编程狮App,免费阅读超1000+编程语言教程
取消
确定
目录

TensorFlow 函数介绍

TensorFlow 函数模块:tf

TensorFlow的image模块

TensorFlow使用之tf.io

TensorFlow使用之tf.keras

TensorFlow函数教程:tf.keras.applications

TensorFlow函数教程:tf.keras.backend

TensorFlow使用之tf.metrics

TensorFlow使用之tf.nn

TensorFlow使用之tf.python_io

TensorFlow 功能函数

关闭

MIP.setData({ 'pageTheme' : getCookie('pageTheme') || {'day':true, 'night':false}, 'pageFontSize' : getCookie('pageFontSize') || 20 }); MIP.watch('pageTheme', function(newValue){ setCookie('pageTheme', JSON.stringify(newValue)) }); MIP.watch('pageFontSize', function(newValue){ setCookie('pageFontSize', newValue) }); function setCookie(name, value){ var days = 1; var exp = new Date(); exp.setTime(exp.getTime() + days*24*60*60*1000); document.cookie = name + '=' + value + ';expires=' + exp.toUTCString(); } function getCookie(name){ var reg = new RegExp('(^| )' + name + '=([^;]*)(;|$)'); return document.cookie.match(reg) ? JSON.parse(document.cookie.match(reg)[2]) : null; }