Jesus had the ability to read the hearts of people. He knew when they had bad motives for what they were saying and doing. We however, do not have that ability. He still loved them, he loved everyone, as does his heavenly Father, God. It was their actions that he didn't like.
If you remember, while Jesus was on earth, he preached to all sorts of people, not only certain ones. Some of these he preached to was criminals, tax collector (which were not like very much during that time period), and women (it was not common for Jewish man to speak to a Samaritan woman). So it is clear that Jesus did in fact love all people. This is why he gave his life for all mankind that they might be saved. It was their actions that wasn't acceptable to him.
John 4:7-9 "A woman of Sa·marʹi·a came to draw water. Jesus said to her: “Give me a drink.” 8 (For his disciples had gone off into the city to buy food.) 9 So the Sa·marʹi·tan woman said to him: “How is it that you, despite being a Jew, ask me for a drink even though I am a Sa·marʹi·tan woman?” (For Jews have no dealings with Sa·marʹi·tans.)"
25, 26 "The woman said to him: “I know that Mes·siʹah is coming, who is called Christ. Whenever that one comes, he will declare all things to us openly.”a 26 Jesus said to her: “I am he, the one speaking to you.”
Matthew 10:3 "Philip and Bar·tholʹo·mew; Thomas and Matthew the tax collector; James the son of Al·phaeʹus; Thad·daeʹus;"
Matthew 5:6 "For if you love those loving you, what reward do you have? Are not also the tax collectors doing the same thing?"
Matthew 9:10 "Later as he was dining in the house, look! many tax collectors and sinners came and began dining with Jesus and his disciples."
Matthew 9:11 "But on seeing this, the Pharisees said to his disciples: “Why does your teacher eat with tax collectors and sinners?”