diff --git a/Cargo.lock b/Cargo.lock index d74acdbf5..d6b6e23cb 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -9,7 +9,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "79faae4620f45232f599d9bc7b290f88247a0834162c4495ab2f02d60004adfb" dependencies = [ "ab_glyph_rasterizer", - "owned_ttf_parser", + "owned_ttf_parser 0.24.0", ] [[package]] @@ -18,6 +18,15 @@ version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c71b1793ee61086797f5c80b6efa2b8ffa6d5dd703f118545808a7f2e27f7046" +[[package]] +name = "addr2line" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5fb1d8e4442bd405fdfd1dacb42792696b0cf9cb15882e5d097b742a676d375" +dependencies = [ + "gimli", +] + [[package]] name = "adler" version = "1.0.2" @@ -54,7 +63,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", - "getrandom", + "getrandom 0.2.15", "once_cell", "version_check", "zerocopy", @@ -178,6 +187,15 @@ version = "1.0.89" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6" +[[package]] +name = "approx" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cab112f0a86d568ea0e627cc1d6be74a1e9cd55214684db5561995f6dad897c6" +dependencies = [ + "num-traits", +] + [[package]] name = "arbitrary" version = "1.3.2" @@ -242,7 +260,7 @@ dependencies = [ "enumflags2", "futures-channel", "futures-util", - "rand", + "rand 0.8.5", "raw-window-handle 0.6.2", "serde", "serde_repr", @@ -436,9 +454,9 @@ dependencies = [ [[package]] name = "autocfg" -version = "1.3.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" +checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" [[package]] name = "av1-grain" @@ -463,6 +481,21 @@ dependencies = [ "arrayvec", ] +[[package]] +name = "backtrace" +version = "0.3.74" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" +dependencies = [ + "addr2line", + "cfg-if", + "libc", + "miniz_oxide 0.8.0", + "object", + "rustc-demangle", + "windows-targets 0.52.6", +] + [[package]] name = "base64" version = "0.22.1" @@ -534,6 +567,18 @@ version = "2.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b81e1519b0d82120d2fd469d5bfb2919a9361c48b02d82d04befc1cdd2002452" +[[package]] +name = "bitvec" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" +dependencies = [ + "funty", + "radium", + "tap", + "wyz", +] + [[package]] name = "bk-tree" version = "0.5.0" @@ -762,9 +807,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.1.21" +version = "1.1.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07b1695e2c7e8fc85310cde85aeaab7e3097f593c91d209d3f9df76c928100f0" +checksum = "9540e661f81799159abee814118cc139a2004b3a3aa3ea37724a1b66530b90e0" dependencies = [ "jobserver", "libc", @@ -1052,6 +1097,15 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7c74b8349d32d297c9134b8c88677813a227df8f779daa29bfc29c183fe3dca6" +[[package]] +name = "conv" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ff10625fd0ac447827aa30ea8b861fead473bb60aeb73af6c1c58caf0d1299" +dependencies = [ + "custom_derive", +] + [[package]] name = "convert_case" version = "0.4.0" @@ -1278,6 +1332,12 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96a6ac251f4a2aca6b3f91340350eab87ae57c3f127ffeb585e92bd336717991" +[[package]] +name = "custom_derive" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef8ae57c4978a2acd8b869ce6b9ca1dfe817bff704c220209fdef2c0b75a01b9" + [[package]] name = "czkawka_cli" version = "7.0.0" @@ -1306,7 +1366,7 @@ dependencies = [ "crc32fast", "crossbeam-channel", "directories-next", - "ffmpeg_cmdline_utils", + "ffmpeg_cmdline_utils 0.1.3", "file-id", "fun_time", "hamming", @@ -1669,6 +1729,30 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a3d8a32ae18130a3c84dd492d4215c3d913c3b07c6b63c2eb3eb7ff1101ab7bf" +[[package]] +name = "enum-utils" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed327f716d0d351d86c9fd3398d20ee39ad8f681873cc081da2ca1c10fed398a" +dependencies = [ + "enum-utils-from-str", + "failure", + "proc-macro2", + "quote", + "serde_derive_internals", + "syn 1.0.109", +] + +[[package]] +name = "enum-utils-from-str" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d49be08bad6e4ca87b2b8e74146987d4e5cb3b7512efa50ef505b51a22227ee1" +dependencies = [ + "proc-macro2", + "quote", +] + [[package]] name = "enumflags2" version = "0.7.10" @@ -1769,6 +1853,25 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af9673d8203fcb076b19dfd17e38b3d4ae9f44959416ea532ce72415a6020365" +[[package]] +name = "failure" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d32e9bd16cc02eae7db7ef620b392808b89f6a5e16bb3497d159c6b92a0f4f86" +dependencies = [ + "backtrace", +] + +[[package]] +name = "fast_image_resize" +version = "2.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc789a40040e11bbe4ba31ca319406805a12fe3f8d71314bbc4bd076602ad55a" +dependencies = [ + "num-traits", + "thiserror", +] + [[package]] name = "fastrand" version = "2.1.1" @@ -1840,6 +1943,30 @@ dependencies = [ "winapi", ] +[[package]] +name = "ffmpeg_cmdline_utils" +version = "0.2.0" +source = "git+https://github.com/Farmadupe/vid_dup_finder_lib?rev=4015aed8efc83bf9f6643158bc714f0767d6de8a#4015aed8efc83bf9f6643158bc714f0767d6de8a" +dependencies = [ + "image 0.24.9", + "serde", + "serde_json", + "thiserror", + "winapi", +] + +[[package]] +name = "ffmpeg_gst_wrapper" +version = "0.1.0" +source = "git+https://github.com/Farmadupe/vid_dup_finder_lib?rev=4015aed8efc83bf9f6643158bc714f0767d6de8a#4015aed8efc83bf9f6643158bc714f0767d6de8a" +dependencies = [ + "ffmpeg_cmdline_utils 0.2.0", + "image 0.24.9", + "serde", + "thiserror", + "url", +] + [[package]] name = "field-offset" version = "0.3.6" @@ -1882,9 +2009,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.33" +version = "1.0.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "324a1be68054ef05ad64b861cc9eaf1d623d2d8cb25b4bf2cb9cdd902b4bf253" +checksum = "a1b589b4dc103969ad3cf85c950899926ec64300a1a46d76c03a6072957036f0" dependencies = [ "crc32fast", "miniz_oxide 0.8.0", @@ -2060,6 +2187,12 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "funty" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" + [[package]] name = "futures-channel" version = "0.3.30" @@ -2194,9 +2327,9 @@ dependencies = [ [[package]] name = "gdk4" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b7d7237c1487ed4b300aac7744efcbf1319e12d60d7afcd6f505414bd5b5dea" +checksum = "c121aeeb0cf7545877ae615dac6bfd088b739d8abee4d55e7143b06927d16a31" dependencies = [ "cairo-rs", "gdk-pixbuf", @@ -2209,9 +2342,9 @@ dependencies = [ [[package]] name = "gdk4-sys" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a67576c8ec012156d7f680e201a807b4432a77babb3157e0555e990ab6bcd878" +checksum = "7d3c03d1ea9d5199f14f060890fde68a3b5ec5699144773d1fa6abf337bfbc9c" dependencies = [ "cairo-sys-rs", "gdk-pixbuf-sys", @@ -2257,6 +2390,17 @@ dependencies = [ "windows-targets 0.48.5", ] +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + [[package]] name = "getrandom" version = "0.2.15" @@ -2265,7 +2409,7 @@ checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", - "wasi", + "wasi 0.11.0+wasi-snapshot-preview1", ] [[package]] @@ -2278,6 +2422,12 @@ dependencies = [ "weezl", ] +[[package]] +name = "gimli" +version = "0.31.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32085ea23f3234fc7846555e85283ba4de91e21016dc0455a16286d87a292d64" + [[package]] name = "gio" version = "0.20.4" @@ -2494,9 +2644,9 @@ dependencies = [ [[package]] name = "gsk4" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3cf2091e1af185b347b3450817d93dea6fe435df7abd4c2cd7fb5bcb4cfda8" +checksum = "aa21a2f7c51ee1c6cc1242c2faf3aae2b7566138f182696759987bde8219e922" dependencies = [ "cairo-rs", "gdk4", @@ -2509,9 +2659,9 @@ dependencies = [ [[package]] name = "gsk4-sys" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6aa69614a26d8760c186c3690f1b0fbb917572ca23ef83137445770ceddf8cde" +checksum = "0f9fb607554f9f4e8829eb7ea301b0fde051e1dbfd5d16b143a8a9c2fac6c01b" dependencies = [ "cairo-sys-rs", "gdk4-sys", @@ -2525,9 +2675,9 @@ dependencies = [ [[package]] name = "gtk4" -version = "0.9.1" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4fe572bf318e5dbc6f5a2f8a25d853f1ae3f42768c0b08af6ca20a18f4057e1" +checksum = "31e2d105ce672f5cdcb5af2602e91c2901e91c72da15ab76f613ad57ecf04c6d" dependencies = [ "cairo-rs", "field-offset", @@ -2558,9 +2708,9 @@ dependencies = [ [[package]] name = "gtk4-sys" -version = "0.9.0" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1114a207af8ada02cf4658a76692f4190f06f093380d5be07e3ca8b43aa7c666" +checksum = "cbe4325908b1c1642dbb48e9f49c07a73185babf43e8b2065b0f881a589f55b8" dependencies = [ "cairo-sys-rs", "gdk-pixbuf-sys", @@ -3083,7 +3233,7 @@ checksum = "9481465fe767d92494987319b0b447a5829edf57f09c52bf8639396abaaeaf78" dependencies = [ "base64", "image 0.25.2", - "rustdct 0.7.1", + "rustdct", "serde", "transpose", ] @@ -3108,6 +3258,24 @@ dependencies = [ "serde_yaml", ] +[[package]] +name = "imageproc" +version = "0.23.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6aee993351d466301a29655d628bfc6f5a35a0d062b6160ca0808f425805fd7" +dependencies = [ + "approx", + "conv", + "image 0.24.9", + "itertools 0.10.5", + "nalgebra", + "num", + "rand 0.7.3", + "rand_distr", + "rayon", + "rusttype", +] + [[package]] name = "imagesize" version = "0.12.0" @@ -3392,7 +3560,7 @@ dependencies = [ "log", "once_cell", "open", - "rand", + "rand 0.8.5", "rayon", "rfd", "rust-embed", @@ -3752,6 +3920,16 @@ dependencies = [ "regex-automata 0.1.10", ] +[[package]] +name = "matrixmultiply" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9380b911e3e96d10c1f415da0876389aaf1b56759054eeb0de7df940c456ba1a" +dependencies = [ + "autocfg", + "rawpointer", +] + [[package]] name = "maybe-rayon" version = "0.1.1" @@ -3856,6 +4034,34 @@ dependencies = [ "linked-hash-map", ] +[[package]] +name = "nalgebra" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fb2d0de08694bed883320212c18ee3008576bfe8c306f4c3c4a58b4876998be" +dependencies = [ + "approx", + "matrixmultiply", + "num-complex", + "num-rational", + "num-traits", + "simba", + "typenum", +] + +[[package]] +name = "ndarray" +version = "0.15.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adb12d4e967ec485a5f71c6311fe28158e9d6f4bc4a447b474184d0f91a8fa32" +dependencies = [ + "matrixmultiply", + "num-complex", + "num-integer", + "num-traits", + "rawpointer", +] + [[package]] name = "ndk" version = "0.9.0" @@ -3932,21 +4138,26 @@ dependencies = [ ] [[package]] -name = "num-bigint" -version = "0.4.6" +name = "num" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" +checksum = "35bd024e8b2ff75562e5f34e7f4905839deb4b22955ef5e73d2fea1b9813cb23" dependencies = [ + "num-bigint", + "num-complex", "num-integer", + "num-iter", + "num-rational", "num-traits", ] [[package]] -name = "num-complex" -version = "0.3.1" +name = "num-bigint" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "747d632c0c558b87dbabbe6a82f3b4ae03720d0646ac5b7b4dae89394be5f2c5" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ + "num-integer", "num-traits", ] @@ -3985,6 +4196,17 @@ dependencies = [ "num-traits", ] +[[package]] +name = "num-iter" +version = "0.1.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1429034a0490724d0075ebb2bc9e875d6503c3cf69e235a8941aa757d83ef5bf" +dependencies = [ + "autocfg", + "num-integer", + "num-traits", +] + [[package]] name = "num-rational" version = "0.4.2" @@ -4284,6 +4506,15 @@ dependencies = [ "objc", ] +[[package]] +name = "object" +version = "0.36.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "084f1a5821ac4c651660a94a7153d27ac9d8a53736203f58b31945ded098070a" +dependencies = [ + "memchr", +] + [[package]] name = "ogg_pager" version = "0.6.1" @@ -4349,6 +4580,15 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" +[[package]] +name = "owned_ttf_parser" +version = "0.15.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05e6affeb1632d6ff6a23d2cd40ffed138e82f1532571a26f527c8a284bb2fbb" +dependencies = [ + "ttf-parser 0.15.2", +] + [[package]] name = "owned_ttf_parser" version = "0.24.0" @@ -4710,6 +4950,25 @@ dependencies = [ "proc-macro2", ] +[[package]] +name = "radium" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + [[package]] name = "rand" version = "0.8.5" @@ -4717,8 +4976,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", - "rand_chacha", - "rand_core", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", ] [[package]] @@ -4728,7 +4997,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ "ppv-lite86", - "rand_core", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", ] [[package]] @@ -4737,7 +5015,25 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom", + "getrandom 0.2.15", +] + +[[package]] +name = "rand_distr" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96977acbdd3a6576fb1d27391900035bf3863d4a16422973a409b488cf29ffb2" +dependencies = [ + "rand 0.7.3", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", ] [[package]] @@ -4766,8 +5062,8 @@ dependencies = [ "once_cell", "paste", "profiling", - "rand", - "rand_chacha", + "rand 0.8.5", + "rand_chacha 0.3.1", "simd_helpers", "system-deps 6.2.2", "thiserror", @@ -4827,6 +5123,12 @@ dependencies = [ "toml 0.5.11", ] +[[package]] +name = "rawpointer" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3" + [[package]] name = "rayon" version = "1.10.0" @@ -4849,11 +5151,11 @@ dependencies = [ [[package]] name = "realfft" -version = "3.3.0" +version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "953d9f7e5cdd80963547b456251296efc2626ed4e3cbf36c869d9564e0220571" +checksum = "390252372b7f2aac8360fc5e72eba10136b166d6faeed97e6d0c8324eb99b2b1" dependencies = [ - "rustfft 6.2.0", + "rustfft", ] [[package]] @@ -4880,7 +5182,7 @@ version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ba009ff324d1fc1b900bd1fdb31564febe58a8ccc8a6fdbb93b543d33b13ca43" dependencies = [ - "getrandom", + "getrandom 0.2.15", "libredox 0.1.3", "thiserror", ] @@ -5004,7 +5306,7 @@ version = "0.14.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6dd52e80cfc21894deadf554a5673002938ae4625f7a283e536f9cf7c17b0d5" dependencies = [ - "num-complex 0.4.6", + "num-complex", "num-integer", "num-traits", "realfft", @@ -5044,6 +5346,12 @@ dependencies = [ "walkdir", ] +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + [[package]] name = "rustc-hash" version = "1.1.0" @@ -5059,36 +5367,13 @@ dependencies = [ "semver", ] -[[package]] -name = "rustdct" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fadcb505b98aa64da1dadb1498b912e3642aae4606623cb3ae952cd8da33f80d" -dependencies = [ - "rustfft 5.1.1", -] - [[package]] name = "rustdct" version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b61555105d6a9bf98797c063c362a1d24ed8ab0431655e38f1cf51e52089551" dependencies = [ - "rustfft 6.2.0", -] - -[[package]] -name = "rustfft" -version = "5.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1869bb2a6ff77380d52ff4bc631f165637035a55855c76aa462c85474dadc42f" -dependencies = [ - "num-complex 0.3.1", - "num-integer", - "num-traits", - "primal-check", - "strength_reduce", - "transpose", + "rustfft", ] [[package]] @@ -5097,7 +5382,7 @@ version = "6.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "43806561bc506d0c5d160643ad742e3161049ac01027b5e6d7524091fd401d86" dependencies = [ - "num-complex 0.4.6", + "num-complex", "num-integer", "num-traits", "primal-check", @@ -5119,6 +5404,16 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "rusttype" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ff8374aa04134254b7995b63ad3dc41c7f7236f69528b28553da7d72efaa967" +dependencies = [ + "ab_glyph_rasterizer", + "owned_ttf_parser 0.15.2", +] + [[package]] name = "rustversion" version = "1.0.17" @@ -5132,7 +5427,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1755646867c36ecb391776deaa0b557a76d3badf20c142de7282630c34b20440" dependencies = [ "rubato", - "rustfft 6.2.0", + "rustfft", ] [[package]] @@ -5157,6 +5452,15 @@ version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" +[[package]] +name = "safe_arch" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3460605018fdc9612bce72735cba0d27efbcd9904780d44c7e3a9948f96148a" +dependencies = [ + "bytemuck", +] + [[package]] name = "same-file" version = "1.0.6" @@ -5238,6 +5542,17 @@ dependencies = [ "syn 2.0.77", ] +[[package]] +name = "serde_derive_internals" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1dbab34ca63057a1f15280bdf3c39f2b1eb1b54c17e98360e511637aef7418c6" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "serde_json" version = "1.0.128" @@ -5328,6 +5643,19 @@ dependencies = [ "libc", ] +[[package]] +name = "simba" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f3fd720c48c53cace224ae62bef1bbff363a70c68c4802a78b5cc6159618176" +dependencies = [ + "approx", + "num-complex", + "num-traits", + "paste", + "wide", +] + [[package]] name = "simd-adler32" version = "0.3.7" @@ -5360,9 +5688,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "skia-bindings" -version = "0.78.0" +version = "0.78.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5ac1da945f92ee2c5ae7999bc679d682fd976ef524b09cc80b5aae971d3e557" +checksum = "d41a3529f83c9db79710935e4e52431c968de7e8d41cdc4e2edbf5639933b5f6" dependencies = [ "bindgen", "cc", @@ -5377,9 +5705,9 @@ dependencies = [ [[package]] name = "skia-safe" -version = "0.78.0" +version = "0.78.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80a2993ab98e8f01c874fc35cfec9a8d216d968b80f7e9b1cb9ac1bf4f6a2f3a" +checksum = "52469ebc0194388c0351b8ce9f2923f0fa6ddedd49dbf6a6af3479ba1dc8f992" dependencies = [ "bitflags 2.6.0", "lazy_static", @@ -5919,6 +6247,12 @@ dependencies = [ "version-compare", ] +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + [[package]] name = "tar" version = "0.4.42" @@ -6239,6 +6573,12 @@ version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "622b09ce2fe2df4618636fb92176d205662f59803f39e70d1c333393082de96c" +[[package]] +name = "ttf-parser" +version = "0.15.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b3e06c9b9d80ed6b745c7159c40b311ad2916abb34a49e9be2653b90db0d8dd" + [[package]] name = "ttf-parser" version = "0.21.1" @@ -6491,21 +6831,36 @@ version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" +[[package]] +name = "vid_dup_finder_common" +version = "0.1.0" +source = "git+https://github.com/Farmadupe/vid_dup_finder_lib?rev=4015aed8efc83bf9f6643158bc714f0767d6de8a#4015aed8efc83bf9f6643158bc714f0767d6de8a" +dependencies = [ + "fast_image_resize", + "image 0.24.9", + "imageproc", + "serde", + "thiserror", + "winapi", +] + [[package]] name = "vid_dup_finder_lib" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6aeb8f9a4a0c8aeb3963a0db7ecd80c92353576c807949faeae08a7b259b0a2" +version = "0.2.0" +source = "git+https://github.com/Farmadupe/vid_dup_finder_lib?rev=4015aed8efc83bf9f6643158bc714f0767d6de8a#4015aed8efc83bf9f6643158bc714f0767d6de8a" dependencies = [ - "ffmpeg_cmdline_utils", + "bitvec", + "enum-utils", + "ffmpeg_gst_wrapper", "image 0.24.9", - "rand", - "rayon", - "rustdct 0.6.0", + "imageproc", + "itertools 0.10.5", + "ndarray", + "rand 0.8.5", + "rustdct", "serde", - "serde_json", "thiserror", - "transpose", + "vid_dup_finder_common", ] [[package]] @@ -6579,6 +6934,12 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" @@ -6799,6 +7160,16 @@ dependencies = [ "rustix", ] +[[package]] +name = "wide" +version = "0.7.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b828f995bf1e9622031f8009f8481a85406ce1f4d4588ff746d872043e855690" +dependencies = [ + "bytemuck", + "safe_arch", +] + [[package]] name = "winapi" version = "0.3.9" @@ -7249,6 +7620,15 @@ dependencies = [ "winapi", ] +[[package]] +name = "wyz" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" +dependencies = [ + "tap", +] + [[package]] name = "x11-clipboard" version = "0.9.2" @@ -7399,7 +7779,7 @@ dependencies = [ "hex", "nix", "ordered-stream", - "rand", + "rand 0.8.5", "serde", "serde_repr", "sha1", @@ -7496,7 +7876,7 @@ dependencies = [ "indexmap 2.5.0", "memchr", "pbkdf2", - "rand", + "rand 0.8.5", "sha1", "thiserror", "time", diff --git a/Cargo.toml b/Cargo.toml index 8cfa2d0b0..491dc4d14 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,6 +17,9 @@ resolver = "2" # until you are ready to occasional crashes panic = "unwind" +# Panics currently with +#overflow-checks = true + # LTO setting is disabled by default, because release mode is usually needed to develop app and compilation with LTO would take a lot of time # But it is used to optimize release builds(and probably also in CI, where time is not so important as in local development) #lto = "thin" diff --git a/czkawka_core/Cargo.toml b/czkawka_core/Cargo.toml index eeb0c9617..776e2556a 100644 --- a/czkawka_core/Cargo.toml +++ b/czkawka_core/Cargo.toml @@ -45,7 +45,7 @@ xxhash-rust = { version = "0.8", features = ["xxh3"] } tempfile = "3.12" # Video Duplicates -vid_dup_finder_lib = "0.1" +vid_dup_finder_lib = { git = "https://github.com/Farmadupe/vid_dup_finder_lib", rev = "4015aed8efc83bf9f6643158bc714f0767d6de8a" } ffmpeg_cmdline_utils = "0.1" # Saving/Loading Cache diff --git a/czkawka_core/src/similar_videos.rs b/czkawka_core/src/similar_videos.rs index e366ecf66..e372c9d87 100644 --- a/czkawka_core/src/similar_videos.rs +++ b/czkawka_core/src/similar_videos.rs @@ -4,16 +4,6 @@ use std::mem; use std::path::{Path, PathBuf}; use std::sync::atomic::Ordering; -use crossbeam_channel::{Receiver, Sender}; -use ffmpeg_cmdline_utils::FfmpegErrorKind::FfmpegNotFound; -use fun_time::fun_time; -use humansize::{format_size, BINARY}; -use log::debug; -use rayon::prelude::*; -use serde::{Deserialize, Serialize}; -use vid_dup_finder_lib::HashCreationErrorKind::DetermineVideo; -use vid_dup_finder_lib::{NormalizedTolerance, VideoHash}; - use crate::common::{check_if_stop_received, delete_files_custom, prepare_thread_handler_common, send_info_and_wait_for_ending_all_threads, VIDEO_FILES_EXTENSIONS}; use crate::common_cache::{extract_loaded_cache, get_similar_videos_cache_file, load_cache_from_file_generalized_by_path, save_cache_to_file_generalized}; use crate::common_dir_traversal::{inode, take_1_per_inode, DirTraversalBuilder, DirTraversalResult, FileEntry, ToolType}; @@ -21,6 +11,13 @@ use crate::common_tool::{CommonData, CommonToolData, DeleteMethod}; use crate::common_traits::{DebugPrint, PrintResults, ResultEntry}; use crate::flc; use crate::progress_data::{CurrentStage, ProgressData}; +use crossbeam_channel::{Receiver, Sender}; +use fun_time::fun_time; +use humansize::{format_size, BINARY}; +use log::debug; +use rayon::prelude::*; +use serde::{Deserialize, Serialize}; +use vid_dup_finder_lib::VideoHash; pub const MAX_TOLERANCE: i32 = 20; @@ -296,7 +293,11 @@ impl SimilarVideos { #[fun_time(message = "match_groups_of_videos", level = "debug")] fn match_groups_of_videos(&mut self, vector_of_hashes: Vec, hashmap_with_file_entries: &HashMap) { - let match_group = vid_dup_finder_lib::search(vector_of_hashes, NormalizedTolerance::new(self.get_params().tolerance as f64 / 100.0f64)); + // Tolerance in library is a value between 0 and 1 + // Tolerance in this app is a value between 0 and 20 + // Default tolerance in library is 0.30 + // We need to allow to set value in range 0 - 0.5 + let match_group = vid_dup_finder_lib::search(vector_of_hashes, self.get_params().tolerance as f64 / 40.0f64); let mut collected_similar_videos: Vec> = Default::default(); for i in match_group { let mut temp_vector: Vec = Vec::new(); @@ -405,14 +406,11 @@ impl PrintResults for SimilarVideos { } pub fn check_if_ffmpeg_is_installed() -> bool { - let vid = "9999czekoczekoczekolada999.txt"; - if let Err(DetermineVideo { - src_path: _a, - error: FfmpegNotFound, - }) = VideoHash::from_path(vid) - { - return false; - } + // let vid = "9999czekoczekoczekolada999.txt"; + // TODO looks that in this version we cannot check if ffmpeg is installed + // if let Err(HashCreationErrorKind::NotVideo(_)) = VideoHash::from_path(vid) { + // return false; + // } true } diff --git a/justfile b/justfile index 85730d149..3b5d26070 100644 --- a/justfile +++ b/justfile @@ -4,8 +4,28 @@ build_all: cargo clippy cargo test -run: - cargo run --bin czkawka_gui +## run + +czkawka: + RUST_BACKTRACE=1 cargo run --bin czkawka_gui +czkawka_r: + RUST_BACKTRACE=1 cargo run --bin czkawka_gui --release + +krokiet: + RUST_BACKTRACE=1 cargo run --bin krokiet +krokiet_r: + RUST_BACKTRACE=1 cargo run --bin krokiet --release +krokiet_dark: + RUST_BACKTRACE=1 SLINT_STYLE=fluent-dark cargo run --bin krokiet + +cli: + RUST_BACKTRACE=1 cargo run --bin czkawka_cli +cli_r: + RUST_BACKTRACE=1 cargo run --bin czkawka_cli --release +cli_help: + cargo run --bin czkawka_cli -- --help + +## Other build: cargo build --bin czkawka_gui @@ -16,26 +36,6 @@ check: check_all: cargo check -krokiet: - cargo run --bin krokiet - -czkawka: - cargo run --bin czkawka_gui - -krokiet_r: - cargo run --bin krokiet --release - -krokiet_dark: - SLINT_STYLE=fluent-dark cargo run --bin krokiet - -czkawka_r: - cargo run --bin czkawka_gui --release - -cli: - cargo run --bin czkawka_cli - -cli_help: - cargo run --bin czkawka_cli -- --help build_krokiet: cargo build --bin krokiet