Skip to content

Commit

Permalink
CNTK v2 library: Fix linux build issues
Browse files Browse the repository at this point in the history
  • Loading branch information
amitaga committed Sep 2, 2016
1 parent 29ea107 commit 79ad971
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Source/CNTKv2LibraryDll/Function.h
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ namespace CNTK
if (leftOperandShape.SubShape(outputRank) != rightOperandShape.SubShape(0, numReductionAxes))
{
InvalidArgument("The %d trailing dimensions of the left operand (%s) do not match the right operand's leading dimensions (%s)",
numReductionAxes,
(int)numReductionAxes,
AsString(leftOperandShape.SubShape(outputRank)).c_str(),
AsString(rightOperandShape).c_str());
}
Expand Down
6 changes: 3 additions & 3 deletions Tests/UnitTests/V2LibraryTests/Seq2Seq.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ void TrainSequenceToSequenceTranslator(const DeviceDescriptor& device, bool useS

auto decoderOutputH = Stabilize<float>(decoderInput, device);
FunctionPtr decoderOutputC;
auto pastValueRecurrenceHookWithBeamSearchReordering = [addBeamSearchReorderingHook, beamSearchReorderHook](const Variable& operand) {
auto pastValueRecurrenceHookWithBeamSearchReordering = [addBeamSearchReorderingHook, beamSearchReorderHook](const FunctionPtr& operand) {
return PastValue(addBeamSearchReorderingHook ? Times(operand, beamSearchReorderHook) : operand);
};

Expand All @@ -114,11 +114,11 @@ void TrainSequenceToSequenceTranslator(const DeviceDescriptor& device, bool useS
else
{
auto isFirst = Sequence::IsFirst(labelEmbedding);
recurrenceHookH = [labelEmbedding, thoughtVectorBroadcastH, isFirst, addBeamSearchReorderingHook, beamSearchReorderHook](const Variable& operand) {
recurrenceHookH = [labelEmbedding, thoughtVectorBroadcastH, isFirst, addBeamSearchReorderingHook, beamSearchReorderHook](const FunctionPtr& operand) {
return ElementSelect(isFirst, thoughtVectorBroadcastH, PastValue(addBeamSearchReorderingHook ? Times(operand, beamSearchReorderHook) : operand));
};

recurrenceHookC = [labelEmbedding, thoughtVectorBroadcastC, isFirst, addBeamSearchReorderingHook, beamSearchReorderHook](const Variable& operand) {
recurrenceHookC = [labelEmbedding, thoughtVectorBroadcastC, isFirst, addBeamSearchReorderingHook, beamSearchReorderHook](const FunctionPtr& operand) {
return ElementSelect(isFirst, thoughtVectorBroadcastC, PastValue(addBeamSearchReorderingHook ? Times(operand, beamSearchReorderHook) : operand));
};
}
Expand Down

0 comments on commit 79ad971

Please sign in to comment.