Last active
November 4, 2019 03:24
-
-
Save redraw/6232095eb39871e6ef3a26ba350f4dbe to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python3 | |
| import os | |
| from gooey import GooeyParser, Gooey | |
| from imagecluster import calc, io as icio, postproc | |
| def run(args): | |
| images, fingerprints, timestamps = icio.get_image_data(args.input) | |
| clusters = calc.cluster(fingerprints, sim=0.5) | |
| output_path = os.path.join(args.input, 'clusters') | |
| postproc.make_links(clusters, output_path) | |
| @Gooey(program_name="ImageCluster", required_cols=1) | |
| def main(): | |
| parser = GooeyParser() | |
| parser.add_argument("input", widget="DirChooser") | |
| parser.add_argument("similarity", default=0.5) | |
| args = parser.parse_args() | |
| run(args) | |
| if __name__ == "__main__": | |
| main() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| git+https://github.com/elcorto/imagecluster | |
| gooey |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment