mirror of
https://github.com/augustin64/projet-tipe
synced 2025-01-23 23:26:25 +01:00
Removal of warnings
This commit is contained in:
parent
47a475a370
commit
2790883586
@ -63,9 +63,8 @@ void* train_thread(void* parameters) {
|
|||||||
float loss = 0.;
|
float loss = 0.;
|
||||||
|
|
||||||
pthread_t tid;
|
pthread_t tid;
|
||||||
LoadImageParameters* load_image_param;
|
LoadImageParameters* load_image_param = (LoadImageParameters*)malloc(sizeof(LoadImageParameters));
|
||||||
if (dataset_type != 0) {
|
if (dataset_type != 0) {
|
||||||
load_image_param = (LoadImageParameters*)malloc(sizeof(LoadImageParameters));
|
|
||||||
load_image_param->dataset = param->dataset;
|
load_image_param->dataset = param->dataset;
|
||||||
load_image_param->index = index[start];
|
load_image_param->index = index[start];
|
||||||
|
|
||||||
@ -118,9 +117,7 @@ void* train_thread(void* parameters) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dataset_type != 0) {
|
|
||||||
free(load_image_param);
|
free(load_image_param);
|
||||||
}
|
|
||||||
|
|
||||||
param->accuracy = accuracy;
|
param->accuracy = accuracy;
|
||||||
param->loss = loss;
|
param->loss = loss;
|
||||||
@ -140,6 +137,7 @@ void train(int dataset_type, char* images_file, char* labels_file, char* data_di
|
|||||||
float loss;
|
float loss;
|
||||||
float batch_loss; // May be redundant with loss, but gives more informations
|
float batch_loss; // May be redundant with loss, but gives more informations
|
||||||
float test_accuracy = 0.; // Used to decrease Learning rate
|
float test_accuracy = 0.; // Used to decrease Learning rate
|
||||||
|
(void)test_accuracy; // To avoid warnings when not used
|
||||||
float accuracy;
|
float accuracy;
|
||||||
float batch_accuracy;
|
float batch_accuracy;
|
||||||
float current_accuracy;
|
float current_accuracy;
|
||||||
|
Loading…
Reference in New Issue
Block a user