Two people have died amid a major search and rescue operation for people who got into difficulty in the sea off the Yorkshire coast.