Integrated analysis of hydrothermal flow through pretreatment