Modified to import from the new "dwi" directory