fix 3d structure caching, add debug messages for descriptor calculation (this may take quite some time)