preprocessing can all be done in Java