phockup | Media sorting tool to organize photos | Computer Vision library
kandi X-RAY | phockup Summary
kandi X-RAY | phockup Summary
Media sorting tool to organize photos and videos from your camera in folders by year, month and day.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Walks the input directory
- Return the path to the output directory
- Return the exif program to use
- Generate a dictionary from a timestamp
- Build a datetime from a date object
- Returns the exif data
- Get file type
- Process files in the directory
- Convert a datestring into a datetime object
- Get the full path to a file
- Build a date object from a file
- Returns the name of the file
- Process an XMP file
- Generate an instance from an exif data
- Process a file
- Convert date to datetime
- Setup logging
- Parse command line arguments
- Check if Exiftool is installed
phockup Key Features
phockup Examples and Code Snippets
Community Discussions
Trending Discussions on phockup
QUESTION
I have a bunch of image files out of google takeout in folders of the format yyyy-MM-dd/img.jpg - I use phockup to organize my photos and it needs the photos to be in yyyy/mm/dd folders. I'd like to keep the dates since google already gave me them.
For example - this folder/image should match
/2018-07-01/test_img.jpg
and be renamed to
/2018/07/01/test_img.jpg
I've tried using bash together with sed and find to use regex capture groups to move the files, but I don't seem to have had much luck. see below for where I currently am
...ANSWER
Answered 2019-Jun-18 at 23:02In addition to my comments above, and that to use {n}
occurrences you will need more than basic regex expression, if I understand correctly you only want to match .jpg
files with the format, e.g. /2018-07-01/test_img.jpg
, then you will either need to limit the find
expression to only find files in the date-formatted directories, or you can have sed
only pass along files from those directories. sed
provides the ability to only match lines of a given format before attempting the substitution using the form:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install phockup
You can use phockup like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page