Package: tag-images-for-google-drive
READMEMotivationSynchronize a CSV database and PNG/JPEG files to add #hashtag in image description.
Then, you can synchronize all files with Google drive and search image withtags.
Google set the metadata of the file from the 'description' metadata in graphic file.SynopsisGoogle drive use only the description meta-data to index an image.
After this synchronisation it's possible to search an image with
"type:image a_hashtag".type:image appleThis tool useExiftool$sudoapt-getinstallexiftool# Debian$sudobrewinstallexiftool# Mac$sudoyuminstallperl-Image-ExifTool# CentOS...
...You can update the tags inside the description in your CSV file,
or use some others tools likeXnViewand extract tags to CSV and descriptions.By default, this tool merge the tags from CSV and files.$# Merge tags from descriptions.csv and selected files, and save all tags in tags.txt$tag_images_for_google_drive-v--dbdescriptions.csv'**/*.png''**/*.jpg'\--tagfiletags.txtBut it's possible to apply tags from database or files only$tag_images_for_google_drive-v--from-db--dbdescriptions.csv'**/*.png''**/*.jpg'$tag_images_for_google_drive-v--from-file--dbdescriptions.csv'**/*.png''**/*.jpg'To add a specific tag for all images in a directory, add it in command line.$tag_images_for_google_drive-v--dbdescriptions.csv-tmyimages'**/*.png''**/*.jpg'The, you can filter theses specifics images withtype:image myimages ....For more informations$tag_images_for_google_drive--helporread the documentionTo synchronize the google files, you can use different tools.
In the proposed Docker image, we use thegoogle-drive-ocamlfuse.The latest versionClone the git repository (see upper button)InstallationDifferent solutions is possible.For windowsUsechcp 16001(utf-8), before use this tools.Installation from one executableCopy the file 'tag_images_for_google_drive.${OS}' to local directoryRename this file to 'tag_images_for_google_drive'And run-it$tag_images_for_google_drive--helpInstallation from PIPIn virtualenv or conda env, use$pipinstalltag_images_for_google_driveThen, run-it$tag_images_for_google_drive--helpInstalltion in DockerFrom the source code, usemake DockerfileWARNING, this image have the credential for manipulate all yours Google filesEventually, create a dedicated volume for the GDrive cache>dockervolumecreate--nametag_image_for_google_driveCreate the container with custom parameters$dockerbuild\-fDockerfile\--build-argOS_VERSION="latest"\--build-argGDRIVE_ROOT_FOLDER="/Images"\--build-argGDRIVE_TEAM_DRIVE_ID=""\--build-argPARAMS="'**/*.png' '**/*.jpg'"\--build-argCRON_FREQUENCE="* */12 * * *"\-t"$(USER)/tag_image_for_google_drive:latest".Start the container$dockerrun--detach--cpus=0.5\--privileged\-vtag_image_for_google_drive:/cache
-i"$(USER)/tag_image_for_google_drive:latest"Inside the container, agoogle-drive-ocamlfuseis installed to synchronize the google files
fromGDRIVE_ROOT_FOLDERin the cache, and a crontab is periodically executed (seeCRON_REQUENCE)
to invoketag_image_for_google_drivewithPARAMS.Installation from sourceGo inside the directory and$makeconfigure
$condaactivatetag_images_for_google_drive
$makeinstallTestsTo test the project$maketestTo validate the typing$maketypingTo validate all the project$makevalidateProject Organization├── Makefile              <- Makefile with commands like `make data` or `make train`
├── README.md             <- The top-level README for developers using this project.
├── docs                  <- A default Sphinx project; see sphinx-doc.org for details
├── setup.py              <- makes project pip installable (pip install -e .[tests])
│                            so sources can be imported and dependencies installed
├── tag_images_for_google_drive                <- Source code for use in this project
└── tests                 <- Unit and integrations tests ((Mark directory as a sources root).