OpenVideoAI/keywords2images.sh

24 lines
485 B
Bash
Raw Normal View History

2024-01-19 19:29:09 +00:00
while IFS= read -r line; do
./image-finder.sh "$line"
done < script-keywords.txt
# Navigate to the img/ directory
cd img/
2024-01-19 20:09:20 +00:00
# Find files with 0 size
find . -type f -size 0 -delete
# Return to the original directory
2024-01-19 19:29:09 +00:00
cd ..
# Add our images to the concat file.
ls -1v img/* | while IFS= read -r file; do
echo "file '$(echo "$file" | sed "s/'/\\\'/g")'"
done > concat.txt
sed -i '/\\/d' concat.txt
2024-06-15 20:07:00 +00:00
cd img
# Resize images in img folder to 4k.
2024-06-15 20:07:00 +00:00
magick * -resize "3840x2160" *
cd ..