| 352 | |
| 353 | template<typename T> |
| 354 | int ArrayCpuGpu<T>::num() const |
| 355 | { |
| 356 | try |
| 357 | { |
| 358 | #ifdef USE_CAFFE |
| 359 | return spImpl->pCaffeBlobT->num(); |
| 360 | #else |
| 361 | return -1; |
| 362 | #endif |
| 363 | } |
| 364 | catch (const std::exception& e) |
| 365 | { |
| 366 | error(e.what(), __LINE__, __FUNCTION__, __FILE__); |
| 367 | return -1; |
| 368 | } |
| 369 | } |
| 370 | |
| 371 | template<typename T> |
| 372 | int ArrayCpuGpu<T>::channels() const |