深度网络是一个组合模型,很自然的的表达为工作于数据块的内连集合。caffe定义了一种网络分层模式的模型。网络定义了一种从输入数据至损失自顶向上的完整网络。数据和导数从保存在caffe前后传递的网络中。blob是一个标准的阵列,统一内存接口框架。blob详细的描述了在caffe中的层与网络中信息是如何保存和通信的。
blob是实际被处理 传递的数据封装,在此机制下提供cpu和gpu之间的同步功能。数学上,一个blob是一个n维阵列。
caffe保存和传递数据通过blobs。
Blobs conceal the computational and mental overhead of mixed CPU/GPU operation by synchronizing from the CPU host to the GPU device as needed. Memory on the host and device is allocated on demand (lazily) for efficient memory usage.
传统的blob图像数据包的维数为 number N x channel K x height H x width W. For example, in a 4D blob, the value at index (n, k, h, w) is physically located at index ((n * K + k) * H + h) * W + w.