- Mass convert large media files on cloud VM instance/cluster into smaller size. Output is generally 10X+ smaller on a 1080P or higher format and almost visually lossless. Can be further down-sized using UHARC if you have many files. Also, way cheaper if you're using cloud VMs for scraping as well. - Quad-core CPU-optimized instances work best in terms of resource _vs_ cost. I've experimented with octa-core instances but the gains aren't linear and rank lower on cost _vs_ time gains. - Use snap for latest ffmpeg release (possibly improved compression algorithm). If you're using ffplay for testing installed through apt, then ffmpeg command here may cause clash. ``` sudo snap install ffmpeg echo "#!/bin/bash" >> Processor.sh echo "for file in ./*.mp4; do ffmpeg -i \"\$file\" -c:v libx265 -preset fast -c:a copy \"H265/\$(basename \"\$file\" .mp4)_x265.mp4\" done" >> Processor.sh mkdir H265 chmod u+x Processor.sh ./Processor.sh ``` ## In one line: > Detach recommended if using SSH. Can be done via screen detach command: `screen -d -m ` ``` sudo snap install ffmpeg && (echo "#!/bin/bash" >> Processor.sh && echo "for file in ./*.mp4; do ffmpeg -i \"\$file\" -c:v libx265 -preset fast -c:a copy \"H265/\$(basename \"\$file\" .mp4)_x265.mp4\" done" >> Processor.sh) && mkdir H265 && chmod +x Processor.sh && ./Processor.sh ```