add script to simplify deleting empty indices