Initial Commit
Had to recreate repo because it was corrupted. FML.
This commit is contained in:
@@ -0,0 +1,50 @@
|
||||
/*#include <Magick++.h>
|
||||
#include <iostream>
|
||||
#include <bitset>
|
||||
#include <climits>
|
||||
|
||||
#include <boost/filesystem/fstream.hpp>
|
||||
#include <string>*/
|
||||
|
||||
#include "DescriptorManager.h"
|
||||
#include <boost/filesystem.hpp>
|
||||
#include <Magick++.h>
|
||||
using namespace std;
|
||||
using namespace Magick;
|
||||
|
||||
//Methods:
|
||||
//5 threshold
|
||||
//4 pearson
|
||||
//3 sobel
|
||||
//2 median
|
||||
//1 numColors
|
||||
//0 averageColor
|
||||
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
string imagename = "im71.jpg";
|
||||
int method = 2;
|
||||
int count = 100;
|
||||
if (argc > 2) {
|
||||
method = atoi(argv[2]);
|
||||
imagename = argv[1];
|
||||
}
|
||||
if (argc > 3) {
|
||||
count = atoi(argv[3]);
|
||||
}
|
||||
|
||||
else {
|
||||
cout << "Usage: " << endl << argv[0] << " [fileName] [methodIndex]" << endl;
|
||||
cout << "Continuing.." << endl;
|
||||
}
|
||||
InitializeMagick(*argv);
|
||||
DescriptorManager* manager = new DescriptorManager("data");
|
||||
//cout << "Loading descriptiors..";
|
||||
manager->loadDescriptors();
|
||||
//cout << "done!" << endl << "Calculating distances.." << endl;
|
||||
manager->similarImages(imagename, method, count);
|
||||
//cout << "done!" << endl << "Outputting map.." << endl;
|
||||
//manager->outputMap();
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user