Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Microsoft/CNTK into fseid…
Browse files Browse the repository at this point in the history
…e/seq2seqsample
  • Loading branch information
U-FAREAST\fseide committed Jun 6, 2016
2 parents 0e57e7b + 23620b6 commit 31b8890
Show file tree
Hide file tree
Showing 158 changed files with 224 additions and 210 deletions.
18 changes: 9 additions & 9 deletions CNTK.sln
Original file line number Diff line number Diff line change
Expand Up @@ -805,7 +805,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CNTKTextFormatReader", "Sou
{F0A9637C-20DA-42F0-83D4-23B4704DE602} = {F0A9637C-20DA-42F0-83D4-23B4704DE602}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "ExperimentalHTKMLFReader", "Source\Readers\ExperimentalHTKMLFReader\ExperimentalHTKMLFReader.vcxproj", "{7B7A51ED-AA8E-4660-A805-D50235A02120}"
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HTKDeserializers", "Source\Readers\HTKDeserializers\HTKDeserializers.vcxproj", "{7B7A51ED-AA8E-4660-A805-D50235A02120}"
ProjectSection(ProjectDependencies) = postProject
{60BDB847-D0C4-4FD3-A947-0C15C08BCDB5} = {60BDB847-D0C4-4FD3-A947-0C15C08BCDB5}
{86883653-8A61-4038-81A0-2379FAE4200A} = {86883653-8A61-4038-81A0-2379FAE4200A}
Expand Down Expand Up @@ -1052,7 +1052,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SequenceToSequence", "Seque
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "CPPEvalClient", "Source\Extensibility\CPPEvalClient\CPPEvalClient.vcxproj", "{578D52A0-3928-4405-A016-F016E8B49031}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ExperimentalHtkmlfReader", "ExperimentalHtkmlfReader", "{977ECCB7-598D-4548-B95B-BACA9CC7D98B}"
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "HtkDeserializers", "HtkDeserializers", "{977ECCB7-598D-4548-B95B-BACA9CC7D98B}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "DNN", "DNN", "{1DBB2575-F5C8-43F4-B982-D05D6ADC2F9B}"
EndProject
Expand All @@ -1064,13 +1064,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SVD", "SVD", "{BA6A65C5-92A
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "FullUtterance", "FullUtterance", "{3BDF52CD-7F3C-42BC-AB78-CF5BBC5F4AB4}"
ProjectSection(SolutionItems) = preProject
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.cpu.txt = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.cpu.txt
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.gpu.txt = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.gpu.txt
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.windows.cpu.txt = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.windows.cpu.txt
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.windows.gpu.txt = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\baseline.windows.gpu.txt
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\cntk.cntk = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\cntk.cntk
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\run-test = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\run-test
Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\testcases.yml = Tests\EndToEndTests\Speech\ExperimentalHtkmlfReader\LSTM\FullUtterance\testcases.yml
Tests\EndToEndTests\Speech\HtkDeserializers\LSTM\FullUtterance\baseline.cpu.txt = Tests\EndToEndTests\Speech\HtkDeserializers\LSTM\FullUtterance\baseline.cpu.txt
Tests\EndToEndTests\Speech\HtkDeserializers\LSTM\FullUtterance\baseline.gpu.txt = Tests\EndToEndTests\Speech\HtkDeserializers\LSTM\FullUtterance\baseline.gpu.txt
Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\baseline.windows.cpu.txt = Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\baseline.windows.cpu.txt
Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\baseline.windows.gpu.txt = Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\baseline.windows.gpu.txt
Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\cntk.cntk = Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\cntk.cntk
Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\run-test = Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\run-test
Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\testcases.yml = Tests\EndToEndTests\Speech\HTKDeserializers\LSTM\FullUtterance\testcases.yml
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Truncated", "Truncated", "{1141DC61-E014-4DEC-9157-F6B1FC055C7A}"
Expand Down
34 changes: 19 additions & 15 deletions Examples/Image/MNIST/AdditionalFiles/mnist_convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@
import struct
import numpy as np

sys.path.append("../../../../Source/Readers/CNTKTextFormatReader")
from uci_to_cntk_text_format_converter import convert

def loadData(src, cimg):
print ('Downloading ' + src)
gzfname, h = urllib.urlretrieve(src, './delete.me')
Expand Down Expand Up @@ -53,21 +50,28 @@ def loadLabels(src, cimg):
os.remove(gzfname)
return res.reshape((cimg, 1))

def load(dataSrc, labelsSrc, cimg):
data = loadData(dataSrc, cimg)
labels = loadLabels(labelsSrc, cimg)
return np.hstack((data, labels))

def savetxt(filename, ndarray):
with open(filename, 'w') as f:
labels = map(' '.join, np.eye(10, dtype=np.uint).astype(str))
for row in ndarray:
row_str = row.astype(str)
label_str = labels[row[-1]]
feature_str = ' '.join(row_str[:-1])
f.write('|labels {} |features {}\n'.format(label_str, feature_str))

if __name__ == "__main__":
trnData = loadData('http://yann.lecun.com/exdb/mnist/train-images-idx3-ubyte.gz', 60000)
trnLbl = loadLabels('http://yann.lecun.com/exdb/mnist/train-labels-idx1-ubyte.gz', 60000)
trn = np.hstack((trnLbl, trnData))
train = load('http://yann.lecun.com/exdb/mnist/train-images-idx3-ubyte.gz',
'http://yann.lecun.com/exdb/mnist/train-labels-idx1-ubyte.gz', 60000)
print 'Writing train text file...'
np.savetxt(r'./../Data/Train-28x28.txt', trn, fmt = '%u', delimiter='\t')
convert(r'./../Data/Train-28x28.txt', r'./../Data/Train-28x28_cntk_text.txt', 1, 784, 0, 1, 10)
os.remove(r'./../Data/Train-28x28.txt');
savetxt(r'./../Data/Train-28x28_cntk_text.txt', train)
print 'Done.'
testData = loadData('http://yann.lecun.com/exdb/mnist/t10k-images-idx3-ubyte.gz', 10000)
testLbl = loadLabels('http://yann.lecun.com/exdb/mnist/t10k-labels-idx1-ubyte.gz', 10000)
test = np.hstack((testLbl, testData))
test = load('http://yann.lecun.com/exdb/mnist/t10k-images-idx3-ubyte.gz',
'http://yann.lecun.com/exdb/mnist/t10k-labels-idx1-ubyte.gz', 10000)
print 'Writing test text file...'
np.savetxt(r'./../Data/Test-28x28.txt', test, fmt = '%u', delimiter='\t')
convert(r'./../Data/Test-28x28.txt', r'./../Data/Test-28x28_cntk_text.txt', 1, 784, 0, 1, 10)
os.remove(r'./../Data/Test-28x28.txt');
savetxt(r'./../Data/Test-28x28_cntk_text.txt', test)
print 'Done.'
35 changes: 20 additions & 15 deletions Examples/Image/MNIST/AdditionalFiles/mnist_convert_python3.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@
import struct
import numpy as np

sys.path.append("../../../../Source/Readers/CNTKTextFormatReader")
from uci_to_cntk_text_format_converter import convert

def loadData(src, cimg):
print ('Downloading ' + src)
gzfname, h = urllib.request.urlretrieve(src, './delete.me')
Expand Down Expand Up @@ -53,20 +50,28 @@ def loadLabels(src, cimg):
return res.reshape((cimg, 1))


def load(dataSrc, labelsSrc, cimg):
data = loadData(dataSrc, cimg)
labels = loadLabels(labelsSrc, cimg)
return np.hstack((data, labels))

def savetxt(filename, ndarray):
with open(filename, 'w', encoding="ascii") as f:
labels = list(map(' '.join, np.eye(10, dtype=np.uint).astype(str)))
for row in ndarray:
row_str = row.astype(str)
label_str = labels[row[-1]]
feature_str = ' '.join(row_str[:-1])
f.write('|labels {} |features {}\n'.format(label_str, feature_str))

if __name__ == "__main__":
trnData = loadData('http://yann.lecun.com/exdb/mnist/train-images-idx3-ubyte.gz', 60000)
trnLbl = loadLabels('http://yann.lecun.com/exdb/mnist/train-labels-idx1-ubyte.gz', 60000)
trn = np.hstack((trnLbl, trnData))
train = load('http://yann.lecun.com/exdb/mnist/train-images-idx3-ubyte.gz',
'http://yann.lecun.com/exdb/mnist/train-labels-idx1-ubyte.gz', 60000)
print ('Writing train text file...')
np.savetxt(r'./../Data/Train-28x28.txt', trn, fmt = '%u', delimiter='\t')
convert(r'./../Data/Train-28x28.txt', r'./../Data/Train-28x28_cntk_text.txt', 1, 784, 0, 1, 10)
os.remove(r'./../Data/Train-28x28.txt');
savetxt(r'./../Data/Train-28x28_cntk_text.txt', train)
print ('Done.')
testData = loadData('http://yann.lecun.com/exdb/mnist/t10k-images-idx3-ubyte.gz', 10000)
testLbl = loadLabels('http://yann.lecun.com/exdb/mnist/t10k-labels-idx1-ubyte.gz', 10000)
test = np.hstack((testLbl, testData))
test = load('http://yann.lecun.com/exdb/mnist/t10k-images-idx3-ubyte.gz',
'http://yann.lecun.com/exdb/mnist/t10k-labels-idx1-ubyte.gz', 10000)
print ('Writing test text file...')
np.savetxt(r'./../Data/Test-28x28.txt', test, fmt = '%u', delimiter='\t')
convert(r'./../Data/Test-28x28.txt', r'./../Data/Test-28x28_cntk_text.txt', 1, 784, 0, 1, 10)
os.remove(r'./../Data/Test-28x28.txt');
savetxt(r'./../Data/Test-28x28_cntk_text.txt', test)
print ('Done.')
26 changes: 15 additions & 11 deletions Examples/Image/Miscellaneous/CIFAR-10/CIFAR_convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@
ImgSize = 32
NumFeat = ImgSize * ImgSize * 3

sys.path.append("../../../../Source/Readers/CNTKTextFormatReader")
from uci_to_cntk_text_format_converter import convert

def readBatch(src, outFmt):
with open(src, 'rb') as f:
d = cp.load(f)
Expand All @@ -38,7 +35,8 @@ def readBatch(src, outFmt):
print ('Format not supported: ' + outFmt)
usage()
sys.exit(1)
return np.hstack((np.reshape(d['labels'], (len(d['labels']), 1)), feat))
res = np.hstack((feat, np.reshape(d['labels'], (len(d['labels']), 1))))
return res.astype(np.int)

def loadData(src, outFmt):
print ('Downloading ' + src)
Expand All @@ -50,7 +48,7 @@ def loadData(src, outFmt):
tar.extractall()
print ('Done.')
print ('Preparing train set...')
trn = np.empty((0, NumFeat + 1))
trn = np.empty((0, NumFeat + 1), dtype=np.int)
for i in range(5):
batchName = './cifar-10-batches-py/data_batch_{0}'.format(i + 1)
trn = np.vstack((trn, readBatch(batchName, outFmt)))
Expand Down Expand Up @@ -86,16 +84,22 @@ def parseCmdOpt(argv):
sys.exit(1)
return fmt

def savetxt(filename, ndarray):
with open(filename, 'w') as f:
labels = map(' '.join, np.eye(10, dtype=np.uint).astype(str))
for row in ndarray:
row_str = row.astype(str)
label_str = labels[row[-1]]
feature_str = ' '.join(row_str[:-1])
f.write('|labels {} |features {}\n'.format(label_str, feature_str))


if __name__ == "__main__":
fmt = parseCmdOpt(sys.argv[1:])
trn, tst = loadData('http://www.cs.toronto.edu/~kriz/cifar-10-python.tar.gz', fmt)
print ('Writing train text file...')
np.savetxt(r'./Train.txt', trn, fmt = '%u', delimiter='\t')
convert(r'./Train.txt', r'./Train_cntk_text.txt', 1, 3072, 0, 1, 10)
os.remove(r'./Train.txt');
savetxt(r'./Train_cntk_text.txt', trn)
print ('Done.')
print ('Writing test text file...')
np.savetxt(r'./Test.txt', tst, fmt = '%u', delimiter='\t')
convert(r'./Test.txt', r'./Test_cntk_text.txt', 1, 3072, 0, 1, 10)
os.remove(r'./Test.txt');
savetxt(r'./Test_cntk_text.txt', tst)
print ('Done.')
1 change: 1 addition & 0 deletions Examples/Image/Miscellaneous/ImageNet/ResNet/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ The following table contains results as well as links to pre-trained models that
| ResNet-18 | 29.57 | 10.41 | [Download](https://www.cntk.ai/resnet/ResNet_18.model)
| ResNet-34 | 27.31 | 8.97 | [Download](https://www.cntk.ai/resnet/ResNet_34.model)
| ResNet-50 | 24.74 | 7.56 | [Download](https://www.cntk.ai/resnet/ResNet_50.model)
| ResNet-152 | 22.57 | 6.44 | [Download](https://www.cntk.ai/resnet/ResNet_152.model)

## Notes
This work is an implementation of ResNets in CNTK. If you are interested in the original implementation of ResNet, follow [this link](https://github.com/KaimingHe/deep-residual-networks).
24 changes: 12 additions & 12 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -368,25 +368,25 @@ $(LIBDIR)/CompositeDataReader.so: $(COMPOSITEDATAREADER_OBJ) | $(CNTKMATH_LIB)
$(CXX) $(LDFLAGS) -shared $(patsubst %,-L%, $(LIBDIR) $(LIBPATH)) $(patsubst %,$(RPATH)%, $(ORIGINDIR) $(LIBPATH)) -o $@ $^ -l$(CNTKMATH)
########################################
# ExperimentalHTKMLFReader plugin
# HTKDeserializers plugin
########################################
EXPERIMENTALHTKMLFREADER_SRC =\
HTKDESERIALIZERS_SRC =\
$(SOURCEDIR)/Readers/HTKMLFReader/DataWriterLocal.cpp \
$(SOURCEDIR)/Readers/HTKMLFReader/HTKMLFWriter.cpp \
$(SOURCEDIR)/Readers/ExperimentalHTKMLFReader/ConfigHelper.cpp \
$(SOURCEDIR)/Readers/ExperimentalHTKMLFReader/Exports.cpp \
$(SOURCEDIR)/Readers/ExperimentalHTKMLFReader/HTKDataDeserializer.cpp \
$(SOURCEDIR)/Readers/ExperimentalHTKMLFReader/HTKMLFReader.cpp \
$(SOURCEDIR)/Readers/ExperimentalHTKMLFReader/MLFDataDeserializer.cpp \
$(SOURCEDIR)/Readers/HTKDeserializers/ConfigHelper.cpp \
$(SOURCEDIR)/Readers/HTKDeserializers/Exports.cpp \
$(SOURCEDIR)/Readers/HTKDeserializers/HTKDataDeserializer.cpp \
$(SOURCEDIR)/Readers/HTKDeserializers/HTKMLFReader.cpp \
$(SOURCEDIR)/Readers/HTKDeserializers/MLFDataDeserializer.cpp \
EXPERIMENTALHTKMLFREADER_OBJ := $(patsubst %.cpp, $(OBJDIR)/%.o, $(EXPERIMENTALHTKMLFREADER_SRC))
HTKDESERIALIZERS_OBJ := $(patsubst %.cpp, $(OBJDIR)/%.o, $(HTKDESERIALIZERS_SRC))
EXPERIMENTALHTKMLFREADER:=$(LIBDIR)/ExperimentalHTKMLFReader.so
ALL+=$(EXPERIMENTALHTKMLFREADER)
SRC+=$(EXPERIMENTALHTKMLFREADER_SRC)
HTKDESERIALIZERS:=$(LIBDIR)/HTKDeserializers.so
ALL+=$(HTKDESERIALIZERS)
SRC+=$(HTKDESERIALIZERS_SRC)
$(LIBDIR)/ExperimentalHTKMLFReader.so: $(EXPERIMENTALHTKMLFREADER_OBJ) | $(CNTKMATH_LIB)
$(LIBDIR)/HTKDeserializers.so: $(HTKDESERIALIZERS_OBJ) | $(CNTKMATH_LIB)
@echo $(SEPARATOR)
$(CXX) $(LDFLAGS) -shared $(patsubst %,-L%, $(LIBDIR) $(LIBPATH)) $(patsubst %,$(RPATH)%, $(ORIGINDIR) $(LIBPATH)) -o $@ $^ -l$(CNTKMATH)
Expand Down
4 changes: 0 additions & 4 deletions Source/Common/DataWriter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,6 @@ DataWriter::DataWriter(const ConfigRecordType& config)
{
writerType = L"HTKMLFReader";
}
else if (writerType == L"ExperimentalHTKMLFWriter" || writerType == L"ExperimentalHTKMLFReader")
{
writerType = L"ExperimentalHTKMLFReader";
}
else if (writerType == L"BinaryWriter" || writerType == L"BinaryReader")
{
writerType = L"BinaryReader";
Expand Down
2 changes: 1 addition & 1 deletion Source/Readers/CompositeDataReader/CompositeDataReader.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ struct Minibatch;

// The whole CompositeDataReader is meant as a stopgap to allow deserializers/transformers composition until SGD talkes
// directly to the new Reader API. The example of the cntk configuration that this reader supports can be found at
// Tests/EndToEndTests/Speech/ExperimentalHtkmlfReader/LSTM/FullUtterance/cntk.cntk
// Tests/EndToEndTests/Speech/HtkDeserializers/LSTM/FullUtterance/cntk.cntk
// CompositeDataReader is a factory for the new readers. Its main responsibility is to read the configuration and create the
// corresponding set of deserializers, the corpus descriptor, transformers, randomizer and packer, providing the following functionality:
// - all input sequences are defined by the corpus descriptor
Expand Down
1 change: 0 additions & 1 deletion Source/Readers/CompositeDataReader/stdafx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
//
// stdafx.cpp : source file that includes just the standard includes
// ExperimentalHTKMLFReader.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
//

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include "HeapMemoryProvider.h"
#include "HTKDataDeserializer.h"
#include "MLFDataDeserializer.h"
#include "StringUtil.h"

namespace Microsoft { namespace MSR { namespace CNTK {

Expand All @@ -39,11 +40,11 @@ extern "C" DATAREADER_API void GetReaderD(IDataReader** preader)
// TODO: Not safe from the ABI perspective. Will be uglified to make the interface ABI.
extern "C" DATAREADER_API bool CreateDeserializer(IDataDeserializer** deserializer, const std::wstring& type, const ConfigParameters& deserializerConfig, CorpusDescriptorPtr corpus, bool primary)
{
if (type == L"HTKDataDeserializer")
if (type == L"HTKFeatureDeserializer")
{
*deserializer = new HTKDataDeserializer(corpus, deserializerConfig, primary);
}
else if (type == L"MLFDataDeserializer")
else if (type == L"HTKMLFDeserializer")
{
*deserializer = new MLFDataDeserializer(corpus, deserializerConfig, primary);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<PropertyGroup Label="Globals">
<ProjectGuid>{7B7A51ED-AA8E-4660-A805-D50235A02120}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>ExperimentalHTKMLFReader</RootNamespace>
<RootNamespace>HTKDeserializers</RootNamespace>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<Import Project="$(SolutionDir)\CNTK.Cpp.props" />
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
//
// stdafx.cpp : source file that includes just the standard includes
// ExperimentalHTKMLFReader.pch will be the pre-compiled header
// HTKMLFDeserializer.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
//

Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion Source/Readers/ImageReader/Exports.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ extern "C" DATAREADER_API void GetReaderD(IDataReader** preader)
// A factory method for creating image deserializers.
extern "C" DATAREADER_API bool CreateDeserializer(IDataDeserializer** deserializer, const std::wstring& type, const ConfigParameters& deserializerConfig, CorpusDescriptorPtr corpus, bool)
{
if (type == L"ImageDataDeserializer")
if (type == L"ImageDeserializer")
*deserializer = new ImageDataDeserializer(corpus, deserializerConfig);
else
// Unknown type.
Expand Down
20 changes: 10 additions & 10 deletions Tests/EndToEndTests/Image/AlexNet/AlexNetComposite.cntk
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ Train=[
useLegacy=false

# A list of deserializers to use.
deserializers=[
deserializers=(
[
type="ImageDataDeserializer"
type="ImageDeserializer"
module="ImageReader"

# Map file which maps images to labels using the following format:
Expand All @@ -23,7 +23,7 @@ Train=[
# Description of input streams
input=[
features=[
transforms=[
transforms=(
[
type="Crop"
# Possible values: Center, Random. Default: Center
Expand All @@ -48,14 +48,14 @@ Train=[
]:[
type="Transpose"
]
]
)
]
labels=[
labelDim=1000
]
]
]
]
)
]
]

Expand All @@ -65,16 +65,16 @@ Test=[
randomize=false

# A list of deserializers to use.
deserializers=[
deserializers=(
[
type="ImageDataDeserializer"
type="ImageDeserializer"
module="ImageReader"
file=$ConfigDir$/val_map.txt

# Description of input streams
input=[
features=[
transforms=[
transforms=(
[
type="Crop"
cropType=Center
Expand All @@ -89,13 +89,13 @@ Test=[
]:[
type="Transpose"
]
]
)
]
labels=[
labelDim=1000
]
]
]
]
)
]
]
Loading

0 comments on commit 31b8890

Please sign in to comment.