Skip to content
Snippets Groups Projects
Commit cd67ce52 authored by Hashim Sharif's avatar Hashim Sharif
Browse files

Fixing Memory Free Bug

parent d26c2a7b
No related branches found
No related tags found
No related merge requests found
......@@ -410,7 +410,8 @@ void convertToFP16(struct Tensor* tensor){
size_t size_in_bytes = tensor->size_in_bytes / 2;
checkCudaErrors(cudaMalloc(&tensor->gpu_half_data, size_in_bytes)); // Allocate memory on GPU
tensors_ptr.push_back(tensor->gpu_half_data);
f2h((float*) tensor->gpu_data, tensor->num_elems, (half*) tensor->gpu_half_data);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment