I don't know where you got that
var content
line from, but its what is causing your problem. It doesn't have a YearID column in it, only the columns you gave it in that first Select. You don't need that line of code at all.
You just need the second one, modified slightly:
public ActionResult FilterImage(int yearID, int eventID, int branchID)
{
List<EventRegistrationViewModel> contentModel = db.eventRegistration
.Select(item => new EventRegistrationViewModel()
{
EventRegistrationID = item.EventRegistrationID,
Image = item.Image,
IsActive = item.IsActive
})
.Where(c => c.IsActive == true && c.YearID == yearID && c.BranchID == branchID)
.Take(15).ToList();
return View(contentModel);
}