dlaperriere / find_similar_images Goto Github PK
View Code? Open in Web Editor NEWReverse image search utility based on perceptual hash algorithms
Reverse image search utility based on perceptual hash algorithms
Hello your program is great.
The current source code looks for similar images and executes the save (copy) function. I am having trouble modifying the source to change the save to the move function.
File.Copy(image_path, copy, false); -> File.Move(image_path, copy, false);
System.IO.IOException_mscorlib.dll
Thanks for your help.
FindSimilarImages.xaml.cs
using (var dlg = new System.Windows.Forms.FolderBrowserDialog())
{
dlg.Description = "Select folder where the images will be saved";
dlg.SelectedPath = Environment.GetFolderPath(Environment.SpecialFolder.Desktop);
dlg.ShowNewFolderButton = true;
var result = dlg.ShowDialog();
if (result == System.Windows.Forms.DialogResult.OK)
{
//save image of interest
var image_name = Path.GetFileName(image_of_interest);
var image_path = image_of_interest;
var copy = Path.Combine(dlg.SelectedPath, image_name);
if (File.Exists(image_path) && !File.Exists(copy))
{
File.Copy(image_path, copy);
}
//save similar images
foreach (var image in similar_images)
{
if (image == null)
{
continue;
}
image_name = image.ImageName;
image_path = image.ImagePath;
copy = Path.Combine(dlg.SelectedPath, image_name);
if (File.Exists(image_path) && !File.Exists(copy))
{
File.Copy(image_path, copy, false);
}
}
}
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.