Namespaces.
The xmlns="http://www.w3.org/1999/xhtml"
means that elements with no prefix in the XML file are actually in the http://www.w3.org/1999/xhtml
namespace, and you need to specify this in the XPath expression using a prefix:
XPathExpression<Element> xpePages =
factory.compile("/h:html/h:body/h:div[@class='ocr_page']",
Filters.element(),
null, // no variables
Namespace.getNamespace("h", "http://www.w3.org/1999/xhtml"));
You must use a prefix, as in XPath no prefix always means no namespace.