mirror of
https://github.com/lordmathis/CUDANet.git
synced 2025-12-23 06:44:24 +00:00
Refactor size calculations in layers and backend
This commit is contained in:
@@ -16,7 +16,7 @@ std::unique_ptr<Backend> BackendFactory::create(BackendType backend_type, const
|
||||
#ifdef USE_CUDA
|
||||
|
||||
if (!CUDANet::Backends::CUDA::is_cuda_available()) {
|
||||
throw std::runtime_error("No CUDA devices found")
|
||||
throw std::runtime_error("No CUDA devices found");
|
||||
}
|
||||
|
||||
auto cuda = std::make_unique<CUDANet::Backends::CUDA>(config);
|
||||
@@ -31,6 +31,7 @@ std::unique_ptr<Backend> BackendFactory::create(BackendType backend_type, const
|
||||
break;
|
||||
|
||||
default:
|
||||
throw std::runtime_error("Invalid backend");
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user