Filter out directories and special files