From 5c067dc44785a761a0243d8cd634e3ac17d548ad Mon Sep 17 00:00:00 2001
From: Joseph Redmon <pjreddie@gmail.com>
Date: Mon, 12 Sep 2016 20:55:20 +0000
Subject: [PATCH] good chance I didn't break anything

---
 src/darknet.c |   11 +++++------
 1 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/src/darknet.c b/src/darknet.c
index 128d231..1b72329 100644
--- a/src/darknet.c
+++ b/src/darknet.c
@@ -66,7 +66,7 @@
             if(l.type == CONVOLUTIONAL){
                 int num = l.n*l.c*l.size*l.size;
                 axpy_cpu(l.n, 1, l.biases, 1, out.biases, 1);
-                axpy_cpu(num, 1, l.filters, 1, out.filters, 1);
+                axpy_cpu(num, 1, l.weights, 1, out.weights, 1);
             }
             if(l.type == CONNECTED){
                 axpy_cpu(l.outputs, 1, l.biases, 1, out.biases, 1);
@@ -80,7 +80,7 @@
         if(l.type == CONVOLUTIONAL){
             int num = l.n*l.c*l.size*l.size;
             scal_cpu(l.n, 1./n, l.biases, 1);
-            scal_cpu(num, 1./n, l.filters, 1);
+            scal_cpu(num, 1./n, l.weights, 1);
         }
         if(l.type == CONNECTED){
             scal_cpu(l.outputs, 1./n, l.biases, 1);
@@ -159,7 +159,7 @@
     for(i = 0; i < net.n; ++i){
         layer l = net.layers[i];
         if(l.type == CONVOLUTIONAL){
-            rescale_filters(l, 2, -.5);
+            rescale_weights(l, 2, -.5);
             break;
         }
     }
@@ -177,7 +177,7 @@
     for(i = 0; i < net.n; ++i){
         layer l = net.layers[i];
         if(l.type == CONVOLUTIONAL){
-            rgbgr_filters(l);
+            rgbgr_weights(l);
             break;
         }
     }
@@ -354,8 +354,7 @@
     gpu_index = -1;
 #else
     if(gpu_index >= 0){
-        cudaError_t status = cudaSetDevice(gpu_index);
-        check_error(status);
+        cuda_set_device(gpu_index);
     }
 #endif
 

--
Gitblit v1.10.0