EdgeFM: Leveraging Foundation Model for Open-set Learning on the Edge