I’ve always taken it as a given that the most time-consuming part of conforming is dialing in all of the repos from offline. But I finally decided to take the time to dive into an XML from Premiere to find out why Scale (usually) came through but Position did not.
I was very surprised by what I found, because the problem is rather simple. Premiere describes translations as a percentage of that clip’s frame size. So if a 1920x1080 clip moves 192 pixels horizontally, Premiere would put a value of .1 in the XML. However, Flame interprets the value in the XML as a percentage of the sequence’s frame size. So if you brought that clip into a 1080x1080 sequence (for a 1:1 social, say) Flame would incorrectly apply a 108 pixel offset.
Premiere’s way makes more sense to me, but for all I know maybe Flame is actually adhering to the XML spec. Regardless of who’s technically correct, we’ve all lost countless hours due to this discrepancy. So I wrote a small Python script that takes in an XML from Premiere, asks for the destination sequence size, and translates it so Flame brings in the correct values.
I’d be happy to share it if anyone’s interested. I think I lack the cred to share files on this forum at the moment though. Please keep in mind that it has not been tested extensively, and is far from error-proofed. It’s possible it could also fix XMLs for Avid or other offline editors, but I haven’t checked yet.
If Autodesk people are reading this, I’m curious why this has been an issue for so many years. This seems like an easy fix to me, but I acknowledge my purview is quite limited.
Noice! Is this why Premiere -> Resolve scale is also often F’d?
It is pretty weird that the Industry standard for edit exchange is from a program that Apple essentially abandoned.
Also, nice user name.
Ah…you have the permissions to upload files but the forum may be blocking a certain file extension on upload. What kind of file are you trying to upload? If its a .py file, I’ve just enabled the upload of .py files. You should be able to upload a .zip as well, so you could try that.
Here it is:
PremiereXML_v01.py (2.1 KB)
python PremiereXML_v01.py file.xml
It will ask you for the resolution of your destination sequence. This should be the resolution of the sequence in Flame.
It’ll dump some info to the Terminal, then put a file called file_out.xml in the same directory as the script.
Bring that XML into Flame as you would normally.
If you get an error, or the repos don’t match, please consider sending me the XML so I can make the script more robust in the future.
Please delete all audio tracks before you create your XML.
If the script throws an error, try further simplifying your timeline.
If offline worked in HD transcodes, and you’re conforming the 4K originals, the Scale will still be incorrect. However, once you get the scale right, the repo should match.
Whoa! This looks super amazing. @KuleshovEffect, are you familiar with the Logik Portal? You can Submit your script and anybody with the Portal and download and install your script.
I will definitely do that, thank you for the suggestion!
@mikev heads up we got a Python script inbound for ya!
Looking forward to checking this out. Do you think you could create a script that works for Flame XMLs? Adding scaling and reposition data so Baselight or Resolve can interpret them.
It is fantastic that you did this, but you shouldn’t have had to. Thanks for doing it!!
The script is now up on the portal. Thanks Ted!
I haven’t tried to get data out of Flame yet, but I’ll look into it!
I’ve just tried this script on a Premiere xml but couldnt fint the out file
The last few lines of the terminal dump looks like this:
Traceback (most recent call last):
File “PremiereXML_v01.py”, line 88, in
File “PremiereXML_v01.py”, line 56, in main
cliphoriz = master.find(".//media/video/samplecharacteristics/width").text
AttributeError: ‘NoneType’ object has no attribute ‘text’
I have very limited knowledge of linux so please be gentle with me
(I didn’t even know that I had to type python in front of the script name)
Awesome! Yeah no rush at all.
Flame doesn’t output scale or position data in their XMLs, AAFs or EDLs. So this might not work. But it would be great if there was a solve for this using python.
Not your fault, this is almost certainly a bug in my script.
If you could send me the XML, I’ll fix this error so my script is more robust in the future.
(If its helpful, XMLs and EDLs are now approved file types to upload and attach to posts here)
In Resolve, when you first start the project, change this setting:
Project Settings → Image Scaling → Input Scaling to “Center crop with no resizing”
That might fix your scale issue. But changing that setting in the middle of a Resolve project could mess with existing repos.
I looked into XMLs from Resolve; this script isn’t ready to handle those yet.
However, I did find that Resolve and Premiere are using the same formula: percentage of clip resolution. So this does seems like a bug in Flame.
I was hoping someone from Autodesk could comment on this. I could make scripts to translate XMLs from every edit software on the planet, but this seems like such an easy fix on their end.
When I follow the steps to report a bug, the Contact page in my Autodesk account says “You don’t have access to this option.”
Thank you for this script! It saved me hours last week, so I put a built a little UI for it. It’s a wip, so it’s not ready for the logik portal.
premiere_xml_ui.py (6.2 KB)
It was built for our facility, so you will need to modify the paths on lines 21 and 23.
I tried to figure out a way to change the xml scale based on the the Proxy Res vs. the Native Res, but the xml.etree.ElementTree thing is way beyond my limited python skills. If anyone has the time to help me with that, it would be awesome.
Autodesk says that FCP XML specification defines how to encode/decode the various data in the file. All vendors supporting the format should follow the specification and the world would only be better.