Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
magicwindyyd
mindspore
提交
ebbccca7
M
mindspore
项目概览
magicwindyyd
/
mindspore
与 Fork 源项目一致
Fork自
MindSpore / mindspore
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
mindspore
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
ebbccca7
编写于
5月 26, 2020
作者:
“
“liuxiao”
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
pylint clean
上级
f4542f81
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
8 addition
and
12 deletion
+8
-12
tests/ut/python/model/test_bert_cell.py
tests/ut/python/model/test_bert_cell.py
+2
-2
tests/ut/python/nn/optim/test_lars.py
tests/ut/python/nn/optim/test_lars.py
+1
-1
tests/ut/python/nn/test_container.py
tests/ut/python/nn/test_container.py
+1
-1
tests/ut/python/nn/test_loss.py
tests/ut/python/nn/test_loss.py
+1
-1
tests/ut/python/nn/test_parameter.py
tests/ut/python/nn/test_parameter.py
+0
-1
tests/ut/python/onnx/test_onnx.py
tests/ut/python/onnx/test_onnx.py
+2
-4
tests/ut/python/predict/test_predict_save_model.py
tests/ut/python/predict/test_predict_save_model.py
+1
-1
tests/ut/python/train/quant/test_quant.py
tests/ut/python/train/quant/test_quant.py
+0
-1
未找到文件。
tests/ut/python/model/test_bert_cell.py
浏览文件 @
ebbccca7
...
...
@@ -107,7 +107,7 @@ class TrainStepWrapForAdamDynamicLr(nn.Cell):
class
TempC2Wrap
(
nn
.
Cell
):
def
__init__
(
self
,
op
,
c1
=
None
,
c2
=
None
,
):
def
__init__
(
self
,
op
,
c1
=
None
,
c2
=
None
,):
super
(
TempC2Wrap
,
self
).
__init__
()
self
.
op
=
op
self
.
c1
=
c1
...
...
@@ -387,7 +387,7 @@ test_case_cell_ops = [
'block'
:
set_train
(
nn
.
Dense
(
in_channels
=
768
,
out_channels
=
3072
,
activation
=
'gelu'
,
weight_init
=
TruncatedNormal
(
0.02
),
)),
weight_init
=
TruncatedNormal
(
0.02
),)),
'desc_inputs'
:
[[
3
,
768
]],
'desc_bprop'
:
[[
3
,
3072
]]}),
(
'GetNextSentenceOutput'
,
{
...
...
tests/ut/python/nn/optim/test_lars.py
浏览文件 @
ebbccca7
...
...
@@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# ============================================================================
import
numpy
as
np
from
collections
import
Counter
import
numpy
as
np
import
mindspore.nn
as
nn
from
mindspore
import
Tensor
,
Parameter
...
...
tests/ut/python/nn/test_container.py
浏览文件 @
ebbccca7
...
...
@@ -13,9 +13,9 @@
# limitations under the License.
# ============================================================================
""" test container """
from
collections
import
OrderedDict
import
numpy
as
np
import
pytest
from
collections
import
OrderedDict
import
mindspore.nn
as
nn
from
mindspore
import
Tensor
...
...
tests/ut/python/nn/test_loss.py
浏览文件 @
ebbccca7
...
...
@@ -60,5 +60,5 @@ def test_SoftmaxCrossEntropyExpand():
loss
=
nn
.
SoftmaxCrossEntropyExpand
()
logits
=
Tensor
(
np
.
random
.
randint
(
0
,
9
,
[
100
,
10
]).
astype
(
np
.
float32
))
labels
=
Tensor
(
np
.
random
.
randint
(
0
,
9
,
[
10
,
]).
astype
(
np
.
float32
))
labels
=
Tensor
(
np
.
random
.
randint
(
0
,
9
,
[
10
,]).
astype
(
np
.
float32
))
_executor
.
compile
(
loss
,
logits
,
labels
)
tests/ut/python/nn/test_parameter.py
浏览文件 @
ebbccca7
...
...
@@ -54,7 +54,6 @@ def test_parameter_tuple_illegal():
def
test_parameter_init_illegal
():
import
numpy
as
np
dat
=
np
.
array
([[
1
,
2
,
3
],
[
2
,
3
,
4
]])
tensor
=
Tensor
(
dat
)
data_none
=
None
...
...
tests/ut/python/onnx/test_onnx.py
浏览文件 @
ebbccca7
...
...
@@ -13,13 +13,11 @@
# limitations under the License.
# ============================================================================
"""ut for model serialize(save/load)"""
import
numpy
as
np
import
os
import
pytest
import
stat
import
time
import
numpy
as
np
import
pytest
import
mindspore.common.dtype
as
mstype
import
mindspore.nn
as
nn
from
mindspore
import
context
from
mindspore.common.parameter
import
Parameter
...
...
tests/ut/python/predict/test_predict_save_model.py
浏览文件 @
ebbccca7
...
...
@@ -20,8 +20,8 @@ Usage:
"""
import
argparse
import
numpy
as
np
import
os
import
numpy
as
np
import
mindspore.context
as
context
import
mindspore.nn
as
nn
...
...
tests/ut/python/train/quant/test_quant.py
浏览文件 @
ebbccca7
...
...
@@ -17,7 +17,6 @@ import numpy as np
from
mobilenetv2_combined
import
MobileNetV2
import
mindspore.context
as
context
import
mindspore.ops.operations
as
P
from
mindspore
import
Tensor
from
mindspore
import
nn
from
mindspore.nn.layer
import
combined
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录