| Article: |
Cleaning iPhoto | |
| Subject: | Use the Force, Luke. | |
| Date: | 2005-01-21 11:07:30 | |
| From: | pixel | |
|
Response to: Use the Force, Luke.
|
||
| ok, so that might be shortened, and it MIGHT work faster, but it sure eats up memory for some reason. I killed iPhoto after it ran for 20 minutes, was using over 500MB of physical and 1.5GB of virtual memory... and it was steadily rising. Anyone have any ideas? | ||
Showing messages 1 through 1 of 1.




This is indeed very inefficient despite being concise.
This version is more memory and processor efficient. I ran it against my 22000 image library and checked 5500 in ten minutes.
tell application "iPhoto"
tell photo library album
set c to count of photos
repeat with myIndex from c to 1 by -1
tell photo myIndex
set {thisWidth, thisHeight} to {width, height}
end tell
if thisWidth < 200 or thisHeight < 200 then
remove photo myIndex
end if
end repeat
end tell
end tell