https://github.com/Microsoft/CNTK
Raw File
Tip revision: 793bdb29a1923bd11dc56d294252da3029c944f1 authored by Chaojun Liu on 08 December 2019, 07:11:36 UTC
fix pillow version
Tip revision: 793bdb2
ChunkCache.cpp
//
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.
//

#define _CRT_SECURE_NO_WARNINGS

#include "ChunkCache.h"

namespace CNTK {

ChunkPtr ChunkCache::GetChunk(ChunkIdType chunkId)
{
    auto it = m_chunkMap.find(chunkId);
    if (it != m_chunkMap.end())
    {
        return it->second;
    }
 
    ChunkPtr chunk = m_deserializer->GetChunk(chunkId);
    m_chunkMap[chunkId] = chunk;
 
    return chunk;
}

}
back to top