Python use set comprehension