Npred cube

Work in progress, pull request for discussion