Welcome Guest

Pages: 1
Batch Process for Unique Values
CarlinSmithPostOctober 12, 2024, 11:57
Beginner
Posts: 29
Registered:
January 1, 2020, 15:15
Normal topicBatch Process for Unique Values

In a previous request the Yate team created for me an Action that created a listing of Unique User Defined Test items which was useful spanning a 140K file library.

Since UDTI can be multiple items this Action had additional logic to deal with those scenarios. While I have been able to modify that original Action to focus on just one Field I have a feeling a far simpler action could be achieved.

My request: Create an action of creating a unique listing (file) of any single Field (label, encodedby, etc.).

Hoping to learn more from the considerable expertise.

Thanks

2MR2PostOctober 12, 2024, 18:16
Avatar photo
Administrator
Posts: 2179
Registered:
August 23, 2012, 19:27
Normal topicBatch Process for Unique Values

I've created an action which allows you to select any number of fields and also will do UDTIs.

Download the action at:

https://2manyrobots.com/actions/Produce-Unique-Value-List.zip

The displayed panel has a help button.

The action will run on selected files in the UI or in the Batch Processor.

Please test before running over your entire collection.

Selecting all fields and running it over your entire collection may not be a good idea due to the amount of memory required to store all the available metadata.

CarlinSmithPostOctober 13, 2024, 13:10
Beginner
Posts: 29
Registered:
January 1, 2020, 15:15
Normal topicBatch Process for Unique Values

Thanks, will test and report back.

CarlinSmithPostOctober 14, 2024, 08:40
Beginner
Posts: 29
Registered:
January 1, 2020, 15:15
Normal topicBatch Process for Unique Values

The script worked very well. One artifact that I found when using this action is I found two albums that had basically some title names that were stored in the "Movement Number" field. I created a quick action to clear those and oddly it didn't work. I loaded one of the two into Yate and executed the action within Yate UI versus via batch. I saw the Movement Number fields get cleared BUT the files were not shown as modified - meaning green status in Yate versus Red which is why the batch process didn't work.

Thanks as always for great support.

2MR2PostOctober 14, 2024, 10:38
Avatar photo
Administrator
Posts: 2179
Registered:
August 23, 2012, 19:27
Normal topicBatch Process for Unique Values

I'm glad the action worked for you.

As far as the anomaly goes, here's the explanation. Movement Number is a numeric field. When determining if changes have occurred, Yate evaluates numeric fields based on their numeric value as opposed to the textual value. This is so fields which were empty and become set to 0 are treated the same. Because of different low level encodings (especially MPEG-4) this type of thing happens constantly. In your case I would assume the text in the field evaluated as 0 so clearing it was not recorded as a change. This is even trickier with boolean fields as empty and 0 are equivalent as yet the fields often flip between them.

As Yate normalizes the numeric fields, doing a forced save fixes the issue as the clear worked ... it just wasn't identified as a change.

This has not come up in 12 years. I'll have to think about it a little.

CarlinSmithPostOctober 14, 2024, 10:52
Beginner
Posts: 29
Registered:
January 1, 2020, 15:15
Normal topicBatch Process for Unique Values

As explained this makes total sense. The good news is the action helped me identify this type of strangeness existed and I manually fixed the albums with a forced save. Re-running the action confirmed it was remediated and no longer existed.

It was also interesting that multiple runs of the action across a number of fields to confirm the data was absent - found a few instances where data existed and cleaned that up. When I ran against "Year" was also able to see a few albums that had dates that included month/day along with year while the bulk of my library is year only. Neither of these are errors but looking for maximum consistency and this action helped me look for these type of things that don't show up easily otherwise.

A thought is should something like Validate Files action check for inconsistent data - ie text information in a numeric field?

2MR2PostOctober 14, 2024, 11:30
Avatar photo
Administrator
Posts: 2179
Registered:
August 23, 2012, 19:27
Normal topicBatch Process for Unique Values

Out of the box, the Year field displays as YYYY. Many users prefer a YYYY-MM-DD appearance (when available). There are various configuration options in Settings - File List - Format the Year field.

Image

2MR2PostOctober 14, 2024, 11:32
Avatar photo
Administrator
Posts: 2179
Registered:
August 23, 2012, 19:27
Normal topicBatch Process for Unique Values

I'll look into Validate Files. It does make sense.

CarlinSmithPostOctober 14, 2024, 12:12
Beginner
Posts: 29
Registered:
January 1, 2020, 15:15
Normal topicBatch Process for Unique Values
Quote from 2MR2 on October 14, 2024, 11:30

Out of the box, the Year field displays as YYYY. Many users prefer a YYYY-MM-DD appearance (when available). There are various configuration options in Settings - File List - Format the Year field.

Image

I was aware of that setting. The script gave an easy way to search 10,000 albums. Yate has been particularly useful to me for these scale operations.

Pages: 1
Mingle Forum by Cartpauj | Version: 1.1.0beta | Page loaded in: 0.036 seconds.