Workflow to sort and join AVID and Editcam .MXF-files

Questions and answers on how to get the most out of FFAStrans
ThomasM
Site Admin
Posts: 231
Joined: Wed Feb 22, 2017 6:36 am

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by ThomasM »

Hey emcodem,

yes, counting and comparing to the highest number - that is what I do in my MXF-Workflow also (MXF_02__CheckMissingMultiFiles). A nice one would be a node directly after the Monitor Image-Sequence-Node that automatically does that and writes the outcome to an .JSON-Log-file.

By the way: How can I generate growing JSON-compatible files? for example, the first workflow gives

Code: Select all

{
	"Key 1": "Value",
	"Key 2": "Value"
}
later or in another Workflow I want to add

Code: Select all

"Key 3": "Value"
but I have to insert "Key 3": "Value" and add a comma after "Key 2": "Value".

Maybe a JSON-Generator-Node? :D :D :D
emcodem wrote: Fri May 15, 2020 10:37 am I like the idea about a "concat" node, what you mean by audio mapping? You imagine the input files having different audio configs or all have the same audio config and you just want to map channels in the "output" file?
Audio-Mapping similar to the Channel-Map-Node for AviSynth. Sometimes it makes sense to have Stereo OR 2ch-mono OR 4ch-mono OR 2 Stereo-streams... I would like to see this in some other nodes too... ;)

I took a short look at the bins of the custom-nodes. puuh..... NodeJS... C#... Powershell... where to begin :? ?

so long,
all the best
tom
momocampo
Posts: 595
Joined: Thu Jun 08, 2017 12:36 pm
Location: France-Paris

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by momocampo »

ThomasM wrote: Fri May 15, 2020 11:15 am I took a short look at the bins of the custom-nodes. puuh..... NodeJS... C#... Powershell... where to begin :? ?
That's exactly my first reaction :lol: :lol: I really have to study that but need time once again...This is @Encodem's babies these customs procs but he is right because there is really potential !
The only thing missing is good programmers :)

;)
B.
emcodem
Posts: 1811
Joined: Wed Sep 19, 2018 8:11 am

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by emcodem »

ThomasM wrote: Fri May 15, 2020 11:15 am yes, counting and comparing to the highest number - that is what I do in my MXF-Workflow also (MXF_02__CheckMissingMultiFiles). A nice one would be a node directly after the Monitor Image-Sequence-Node that automatically does that and writes the outcome to an .JSON-Log-file.
Thats true and the responsibility of @admin lets see what he has to say about it...
ThomasM wrote: Fri May 15, 2020 11:15 am By the way: How can I generate growing JSON-compatible files? for example, the first workflow gives

Code: Select all

{
	"Key 1": "Value",
	"Key 2": "Value"
}
later or in another Workflow I want to add

Code: Select all

"Key 3": "Value"
but I have to insert "Key 3": "Value" and add a comma after "Key 2": "Value".

Maybe a JSON-Generator-Node? :D :D :D
Hehe, a json generator node would maybe just be as complex as scripting the stuff on your own. There are many possibilities about how your JSON strucutre could look like.
For your example, just adding a simple object at the end of a json, you can just use regex like (.+?)}$ - this selects everything until the last "}". Then you just append your object like "mykey":"myvalue"}
If your value is not JSON safe, you must add a middle step and JSON escape your value before you add it, so the lines in a populate vars proc could look like this:

Code: Select all

%s_json% = $regext($read("c:\file_of_interest.json"),(.+?)}$)
%s_escaped_val% = $jsonencode("%s_yourvalue%")
%s_json% = %s_json%,"NEWKEY":"%s_escaped_val%"}
ThomasM wrote: Fri May 15, 2020 11:15 am Audio-Mapping similar to the Channel-Map-Node for AviSynth. Sometimes it makes sense to have Stereo OR 2ch-mono OR 4ch-mono OR 2 Stereo-streams... I would like to see this in some other nodes too... ;)
Yeahhh but my question was if you want to map channels in each separate input file or only in the "final output"?
ThomasM wrote: Fri May 15, 2020 11:15 am I took a short look at the bins of the custom-nodes. puuh..... NodeJS... C#... Powershell... where to begin :? ?
Weeeellll... you can just start using the ones i already created, instead of directly dive into developing ;-)
Custom nodes is a pretty new function in ffastrans, it has a good error potential there and where, i need some more experienced peoploe like you using the custom nodes and report if they experience any troubles while workflow building or using the nodes themselves. It looks pretty stable until now but the error potential is realatively high overall.


...if you want to develop nodes, you need to deal first with a totally different beast: HTML+javascript for generating the User interface - this is where you would probably start, the UI. The language of the backend processor is your choice, it can be anything, you can even use batch if you like but you would need to use some language that can read and modify JSON files to give calculated values back to ffastrans.
If you have experience with any kind of scripting other than batch, let me know and i will post an example for you.
emcodem, wrapping since 2009 you got the rhyme?
ThomasM
Site Admin
Posts: 231
Joined: Wed Feb 22, 2017 6:36 am

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by ThomasM »

Hy emcodem,

furthermore of counting the files and comparing them to the highest number, the Workflow I mentioned also saves the missing files to a list.txt for generating missing media with a note to the user. That is what I want to do for a .DPX-workflow also. I can use most of my work so far.

Many thanks for the idea (and the solution...) with the PopulateValues-Node for adding JSON-values!

It is hard for me to dive into development of custom nodes as I am no programmer and my programming-skills are more copy-and-paste from StackOverflow & co... But I will try.

Cheers,
tom
emcodem
Posts: 1811
Joined: Wed Sep 19, 2018 8:11 am

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by emcodem »

Coool... well i designed it in a way that copy/paste coding new processors should be easy.
Looking forward to hear about your experiences and questions about building custom procs!
emcodem, wrapping since 2009 you got the rhyme?
momocampo
Posts: 595
Joined: Thu Jun 08, 2017 12:36 pm
Location: France-Paris

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by momocampo »

ThomasM wrote: Mon May 18, 2020 7:27 am It is hard for me to dive into development of custom nodes as I am no programmer and my programming-skills are more copy-and-paste from StackOverflow & co... But I will try.
Hey Tom, this sentence makes you my new best friend :lol: :lol:
ThomasM
Site Admin
Posts: 231
Joined: Wed Feb 22, 2017 6:36 am

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by ThomasM »

@Benjamin...

...high five! :D :lol: :D
momocampo
Posts: 595
Joined: Thu Jun 08, 2017 12:36 pm
Location: France-Paris

Re: Workflow to sort and join AVID and Editcam .MXF-files

Post by momocampo »

;) :lol:
Post Reply