Answer the question
In order to leave comments, you need to log in
What method to check the properties of files and the quality of pictures in large quantities?
Good afternoon! The essence of the task: to audit the quality of images for products, and this is over 40k files.
I want to get a list of files that have dimensions less than 200x200px, image weight greater than 2M, or number of dots less than 4px.
You need to find out which files are of low quality and which are of high quality and get a list with parameters.
How to approach this task? Write something in C or is it possible through .bat?
Answer the question
In order to leave comments, you need to log in
Download the powershell script.
For example, with this script I collect music over 1 megabyte in order to discard skits and small intros.
"Собираем информацию обо всех mp3 файлах в указанной папке и её подпапках... Ждите..."
$save = Get-ChildItem -Recurse -LiteralPath $sourceDirectory | where{$_.extension -eq '.mp3'}
$res = 0..$save.Length
for( $i = 0; $i -lt $save.Length; $i++ )
{
if( ($save[$i].length / 1MB) -gt 1 )
{
$res[$i] = $save[$i].fullname
Out-File -FilePath "random_music_data.txt" -InputObject $res[$i] -Append
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question