官术网_书友最值得收藏!

Ranking (dimensions) of a tensor

The rank of a tensor is the number of dimensions it has, that is, the number of indices that are required to specify any particular element of that tensor.

The rank of a tensor can be ascertained with this, for example:

tf.rank(t2)

The output will be as follows:

<tf.Tensor: id=53, shape=(), dtype=int32, numpy=3>
(the shape is () because the output here is a scalar value)
主站蜘蛛池模板: 陇川县| 湘阴县| 凤冈县| 定远县| 板桥市| 长兴县| 印江| 增城市| 红原县| 新建县| 红原县| 柞水县| 玛纳斯县| 将乐县| 沙坪坝区| 曲松县| 永丰县| 霞浦县| 漳平市| 太保市| 长子县| 佳木斯市| 玉溪市| 磐石市| 广丰县| 万源市| 永宁县| 克东县| 年辖:市辖区| 山丹县| 中超| 阿克苏市| 铁力市| 舟山市| 枣庄市| 长顺县| 海原县| 永善县| 郸城县| 衡阳县| 余姚市|