def xslt_transformation(xml, template):
transformer = ET.XSLT(<EOL>_read_template(template)<EOL>)<EOL>newdom = transformer(<EOL>_read_marcxml(xml)<EOL>)<EOL>return ET.tostring(newdom, pretty_print=True, encoding="<STR_LIT:utf-8>")<EOL>
Transform `xml` using XSLT `template`.

Args:
    xml (str): Filename or XML string. Don't use ``\\n`` in case of
               filename.
    template (str): Filename or XML string. Don't use ``\\n`` in case of
                    filename.

Returns:
    str: Transformed `xml` as string.