addressed most CR feedback
This commit is contained in:
Родитель
ae653c6fba
Коммит
ecaa6cf423
|
@ -2,6 +2,7 @@ name: cntk-py34
|
||||||
channels: !!python/tuple
|
channels: !!python/tuple
|
||||||
- defaults
|
- defaults
|
||||||
dependencies:
|
dependencies:
|
||||||
|
- h5py=2.6.0=np111py34_2
|
||||||
- jupyter=1.0.0=py34_3
|
- jupyter=1.0.0=py34_3
|
||||||
- matplotlib=1.5.3=np111py34_0
|
- matplotlib=1.5.3=np111py34_0
|
||||||
- numpy=1.11.2=py34_0
|
- numpy=1.11.2=py34_0
|
||||||
|
|
|
@ -2,6 +2,7 @@ name: cntk-py35
|
||||||
channels: !!python/tuple
|
channels: !!python/tuple
|
||||||
- defaults
|
- defaults
|
||||||
dependencies:
|
dependencies:
|
||||||
|
- h5py=2.6.0=np111py35_2
|
||||||
- jupyter=1.0.0=py35_3
|
- jupyter=1.0.0=py35_3
|
||||||
- matplotlib=1.5.3=np111py35_0
|
- matplotlib=1.5.3=np111py35_0
|
||||||
- numpy=1.11.2=py35_0
|
- numpy=1.11.2=py35_0
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
name: cntk-py34
|
name: cntk-py34
|
||||||
dependencies:
|
dependencies:
|
||||||
|
- h5py=2.6.0=np111py34_2
|
||||||
- jupyter=1.0.0=py34_3
|
- jupyter=1.0.0=py34_3
|
||||||
- matplotlib=1.5.3=np111py34_0
|
- matplotlib=1.5.3=np111py34_0
|
||||||
- numpy=1.11.2=py34_0
|
- numpy=1.11.2=py34_0
|
||||||
|
|
|
@ -0,0 +1,24 @@
|
||||||
|
# Copyright (c) Microsoft. All rights reserved.
|
||||||
|
|
||||||
|
# Licensed under the MIT license. See LICENSE.md file in the project root
|
||||||
|
# for full license information.
|
||||||
|
# ==============================================================================
|
||||||
|
|
||||||
|
import os
|
||||||
|
import re
|
||||||
|
|
||||||
|
abs_path = os.path.dirname(os.path.abspath(__file__))
|
||||||
|
notebook = os.path.join(abs_path, "..", "..", "..", "..", "Tutorials", "CNTK_205_Artistic_Style_Transfer.ipynb")
|
||||||
|
|
||||||
|
def test_cntk_205_artistic_style_transfer_noErrors(nb):
|
||||||
|
errors = [output for cell in nb.cells if 'outputs' in cell
|
||||||
|
for output in cell['outputs'] if output.output_type == "error"]
|
||||||
|
assert errors == []
|
||||||
|
|
||||||
|
expectedObjective = '7916146.0'
|
||||||
|
|
||||||
|
def test_cntk_205_artistic_style_transfer_evalCorrect(nb):
|
||||||
|
testCell = [cell for cell in nb.cells
|
||||||
|
if cell.cell_type == 'code' and re.search('objfun(xstar', cell.source)]
|
||||||
|
assert len(testCell) == 1
|
||||||
|
assert testCell[0].outputs[0]['data']['text/plain'] == expectedEvalError
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
Загрузка…
Ссылка в новой задаче