Shark seems to be broken
Closed this issue · 2 comments
Zedonboy commented
I built shark library from Git Source.(with visual studio).
Added the include files.
wrote a simple code
`
#include <shark/Algorithms/Trainers/CSvmTrainer.h> // the C-SVM trainer
#include <shark/Models/Kernels/GaussianRbfKernel.h> //the used kernel for the SVM
#include <shark/ObjectiveFunctions/Loss/ZeroOneLoss.h> //used for evaluation of the classifier
#include <shark/Data/DataDistribution.h> //includes small toy distributions
#include <shark/Data/Csv.h>
#include <shark/Algorithms/Trainers/LDA.h>
#include <shark/ObjectiveFunctions/Loss/ZeroOneLoss.h>
#include "stdafx.h"
using namespace shark;
int main(int argc, char **argv) {
ClassificationDataset data;
try
{
importCSV(data, argv[1], LAST_COLUMN, ' ');
}
catch (...)
{
exit(EXIT_FAILURE);
}
ClassificationDataset test = splitAtElement(data, static_cast<std::size_t>(0.8*data.numberOfElements()));
}
`
I get these errors
shark: namespace does not exists
Cannot open file shark/core/shark.h
Classification identifier not declared
Checked the include file, all I see is "shark.h.in"
Whats the Issues? The last time i asked, A shark official told me latest shark is version 4.0.0
The Website http://image.diku.dk/shark/index.html is showing 3.0.0<-<-<- (Whats this guy saying?)
Zedonboy commented
Hi sometimes Visual Studio Can be a little bit weird,
make sure "stdafx.h" is at the top
Ulfgard commented
I assume the following:
1. you have not installed shark after building
2. you are also not generating your VC solution using CMake
In that case, you need to add the generated Shark.h file to your include path. The path is likely something like $SHARK/build/{Debug or Release}/include/shark
…________________________________
From: Zedonboy [notifications@github.com]
Sent: Saturday, July 21, 2018 1:22 AM
To: Shark-ML/Shark
Cc: Subscribed
Subject: [Shark-ML/Shark] Shark seems to be broken (#247)
I built shark library from Git Source.(with visual studio).
Added the include files.
wrote a simple code
`
#include <shark/Algorithms/Trainers/CSvmTrainer.h> // the C-SVM trainer
#include <shark/Models/Kernels/GaussianRbfKernel.h> //the used kernel for the SVM
#include <shark/ObjectiveFunctions/Loss/ZeroOneLoss.h> //used for evaluation of the classifier
#include <shark/Data/DataDistribution.h> //includes small toy distributions
#include <shark/Data/Csv.h>
#include <shark/Algorithms/Trainers/LDA.h>
#include <shark/ObjectiveFunctions/Loss/ZeroOneLoss.h>
#include "stdafx.h"
using namespace shark;
int main(int argc, char **argv) {
ClassificationDataset data;
try
{
importCSV(data, argv[1], LAST_COLUMN, ' ');
}
catch (...)
{
exit(EXIT_FAILURE);
}
ClassificationDataset test = splitAtElement(data, static_cast<std::size_t>(0.8*data.numberOfElements()));
}
`
I get these errors
shark: namespace does not exists
Cannot open file shark/core/shark.h
Classification identifier not declared
Checked the include file, all I see is "shark.h.in"
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#247>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AOWTBneHr3W1wQwXaP02mi-9wu2Vwo-gks5uImYjgaJpZM4VZYhG>.