2021-11-12 11:48:07 +08:00
|
|
|
|
mindspore.ParameterTuple
|
|
|
|
|
|
========================
|
|
|
|
|
|
|
|
|
|
|
|
.. py:class:: mindspore.ParameterTuple(iterable)
|
|
|
|
|
|
|
|
|
|
|
|
参数元组的类。
|
|
|
|
|
|
|
2021-12-30 19:27:21 +08:00
|
|
|
|
.. note::
|
|
|
|
|
|
该类把网络参数存储到参数元组集合中。
|
2021-11-12 11:48:07 +08:00
|
|
|
|
|
|
|
|
|
|
.. py:method:: clone(prefix, init='same')
|
|
|
|
|
|
|
|
|
|
|
|
按元素克隆 `ParameterTuple` 中的数值,以生成新的 `ParameterTuple` 。
|
|
|
|
|
|
|
|
|
|
|
|
**参数:**
|
|
|
|
|
|
|
2021-12-02 20:06:28 +08:00
|
|
|
|
- **prefix** (str) - 参数的命名空间。
|
|
|
|
|
|
- **init** (Union[Tensor, str, numbers.Number]) - 初始化参数的shape和dtype。 `init` 的定义与 `Parameter` API中的定义相同。默认值:'same'。
|
2021-11-12 11:48:07 +08:00
|
|
|
|
|
|
|
|
|
|
**返回:**
|
|
|
|
|
|
|
2021-11-25 16:44:52 +08:00
|
|
|
|
新的参数元组。
|