farmadupe / vid_dup_finder_lib Goto Github PK
View Code? Open in Web Editor NEWa rust library to find near-duplicate video files
License: Apache License 2.0
a rust library to find near-duplicate video files
License: Apache License 2.0
Today I finished implementing this library in czkawka and results can be seen here - qarmin/czkawka#460
It was surprisingly easy to do(most of time took preparing GUI)
In app I use custom system to save cache to text files, so I need info about each element from VideoHash.
I found that currenty it is not possible to do it, so I had to create custom fork.
Changes from this fork are visible here(I used rust formatter, so there is a lot diffs from this tool) - qarmin@a480977.
It would be good to integrate this or similar changes to project, because this will allow me to work with upstream version of this library and get always the newest features.
Since I load hashes from file, then I need to create VideoHash
object manually so I added this function
pub fn with_start_data(
duration: u32,
src_path: impl AsRef<Path>,
hash: [u64; HASH_QWORDS],
num_frames: u32,
) -> Self {
VideoHash {
hash,
num_frames,
src_path: src_path.as_ref().to_path_buf(),
duration,
}
}
Also there is no possibility to get hash
or num_frames
from VideoHash so I added this functions
/// The hash.
pub fn hash(&self) -> &[u64; HASH_QWORDS] {
&self.hash
}
pub fn num_frames(&self) -> u32 {
self.num_frames
}
The last thing is that const HASH_QWORDS
is not public.
I need to check if number of loaded hash elements is equal to number of needed hash elements, so access to such constant would be really helpful(for now I have hardcoded number 19)
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.