Open EmilyJYN opened 1 year ago
As much as I'd love to have this feature too, I can't see how this would make sense for users in general. The concept of an album in Photos is just a mechanism to group photos logically, not physically. That means that you can add photos to as many albums as you want and these are just references, not copies.
So I have an album folder called "Course Note"
Could you please post what a call with "--list-albums" gives you regarding the mentioned folders? I guess it could be just a matter of spelling and/or using the right slash...
Thanks Jörg
Saving to folders named by album is useful to me. Downloading in linux/windows to one huge All Photos folder is unmanageable. I have over 500 albums 17,000 assets, so I implemented it in my fork with a set of other features:
Check out my fork of icloud_photo_downloader and accompanying pyicloud repo too. Features added to icloud_photo_downloader:
Folder by date good
If we could run something like:
icloudpd -d x -u x —create-json-album-listing <album_name>
# and/or:
icloudpd -d x -u x —create-json-album-listing all_albums
Where —create-json-album-listing x
produces a json file listing per album (or all albums) containing all of the file names and locally downloaded paths (or file hash)
This way we have all the info needed to recreate the albums without duplicating the files, it's a more complete backup imo.
If we could run something like:
icloudpd -d x -u x —create-json-album-listing <album_name> # and/or: icloudpd -d x -u x —create-json-album-listing all_albums
Where
—create-json-album-listing x
produces a json file listing per album (or all albums) containing all of the file names and locally downloaded paths (or file hash)This way we have all the info needed to recreate the albums without duplicating the files, it's a more complete backup imo. If you look at the PhotoAsset table in icloudpd.db you can get that info already, e.g. sqlite3 icloudpd.db "select * from PhotoAsset" id|filename|size|created|asset_date|added_date|dimensionX|dimensionY|item_type|item_type_extension|path|md5|album AejGSLcEgZoHqzEkqFxykNkTGxX4|73a1caf0-3a3b-4646-95fe-724da1f74e84.jpg|229203|2023-06-04 15:15:43.000000+00:00|2023-06-04 15:15:43.000000+00:00|2023-06-04 16:11:30.453000+00:00|1600|1200|image|JPG|WhatsApp/73a1caf0-3a3b-4646-95fe-724da1f74e84.jpg|31923fdb974edade95f592a830d0321d|WhatsApp ....
I'll think about adding a new feature. Something like this: ?
[
{
"album_name" : "Some Album Name",
"filename" : "some file name.heic",
"relative_path" : "Some Album Name/some_file name.heic",
"absolute_path" : "/home/username/Pictures/iCloud Photos/Some Album Name/some file name.heic"
},
{
...
{
]
I implemented the catalog.json output when using --create-json-listing. You can pull this repo along with my fork of pyicloud as a dependent repo.
structure is as follows, with example here:
{
catalog_attributes,
...
albums[
{
album_attributes,
....
assets[
asset_attributes,
...
]
},
....
]
}
{
"icloud_username": "username@gmail.com",
"directory": "/home/username/Pictures/iCloud Photos",
"albums": [
{
"album_name": "WhatsApp",
"assets": [
{
"id": "AfRuw5AKo2JEP+1r5ciAWSQJTvQh",
"filename": "9133a2a3-25b7-47dd-9205-f9ea607449ff.jpg",
"size": 96806,
"created": "2023-09-12T17:08:37+00:00",
"asset_date": "2023-09-12T17:08:37+00:00",
"added_date": "2023-09-13T00:02:07.680000+00:00",
"x": 1080,
"y": 1920,
"item_type": "image",
"item_type_extension": "JPG",
"path": "WhatsApp/9133a2a3-25b7-47dd-9205-f9ea607449ff.jpg",
"md5": "17bf7eb1d69fd460d098c96a163f6f8d",
"album": "WhatsApp",
"file_size": 96806
},
{
"id": "AaaSuI//3ZZ6CzoESk5Cw56kZy07",
"filename": "b603edd1-bcb9-4f8d-967b-0896d741aaaa.mp4",
"size": 8692803,
"created": "2023-09-08T12:18:09+00:00",
"asset_date": "2023-09-08T12:18:09+00:00",
"added_date": "2023-09-08T12:49:42.097000+00:00",
"x": 480,
"y": 848,
"item_type": "movie",
"item_type_extension": "MP4",
"path": "WhatsApp/b603edd1-bcb9-4f8d-967b-0896d741aaaa.mp4",
"md5": "d1984aff65eb83fa171c595ab540d4cf",
"album": "WhatsApp",
"file_size": 8692803
},
Summary
Is there a way to download photos from albums in folders?
Context
So I have an album folder called "Course Note", and then there are albums like "Math 209", "ECE 332", etc. However, when I try to download the folder by "--album Course_notes", here is the message:
Apparently, nothing was downloaded.
And then when I tried "--album Course_notes\ECE332", here is the error message:![image](https://user-images.githubusercontent.com/52183621/197162940-68e94b5e-b4b5-4f37-a378-e9a675a244e2.png)
Is this feature not available yet? I saw some other people having the same need as I do: https://github.com/icloud-photos-downloader/icloud_photos_downloader/issues/125#issuecomment-801943814