From 01686065c65ef45d7304f7f9426d48062d407a5f Mon Sep 17 00:00:00 2001 From: Yangqing Jia Date: Sat, 16 Nov 2013 18:41:28 -0800 Subject: [PATCH] removed the StillFresh function that was used to make sure training does not happen with an earlier version of code. --- src/caffe/common.cpp | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/caffe/common.cpp b/src/caffe/common.cpp index 54ab476..c5dcd10 100644 --- a/src/caffe/common.cpp +++ b/src/caffe/common.cpp @@ -9,17 +9,6 @@ namespace caffe { shared_ptr Caffe::singleton_; -inline bool StillFresh() { - struct tm fresh_time; - fresh_time.tm_year = 200; - fresh_time.tm_mon = 1; - fresh_time.tm_mday = 1; - fresh_time.tm_hour = 0; - fresh_time.tm_min = 0; - fresh_time.tm_sec = 0; - return (difftime(time(NULL), mktime(&fresh_time)) < 0); -} - long cluster_seedgen(void) { long s, seed, pid; @@ -33,11 +22,6 @@ long cluster_seedgen(void) { Caffe::Caffe() : mode_(Caffe::CPU), phase_(Caffe::TRAIN), cublas_handle_(NULL), curand_generator_(NULL), vsl_stream_(NULL) { - // A simple way to set an expire time - not for coding geeks, but meh. - // It simply works by skipping creating the streams. - if (!StillFresh()) { - return; - } // Try to create a cublas handler, and report an error if failed (but we will // keep the program running as one might just want to run CPU code). if (cublasCreate(&cublas_handle_) != CUBLAS_STATUS_SUCCESS) { -- 2.7.4