Learning good views through intelligent galleries