with open(schema_file, 'r') as f:
    schema_root = etree.XML(f.read())
schema = etree.XMLSchema(schema_root)
xmlparser = etree.XMLParser(schema=schema)
filenames = ['input1.xml', 'input2.xml', 'input3.xml']
for filename in filenames:
    if validate(xmlparser, filename):
        print('%s validates' % filename)
else:
    print("%s doesn't validate" % filename)
XML (.xsd) feed validation against a schema