Effective ways of encouraging "weak" students to make use of office hours
I have found personal (email) invitations to be very effective at getting certain students to come to office hours. (After attending once by personal invitation, they seem to be much more likely to come again without an invitation.)
The emails typically look something like this:
Hi Jane,
I noticed that some students, including you, had trouble with the theoretical basket weaving questions on Homework 3. I would be happy to review this topic with you during my office hours this Monday, 3-6PM in room 901. If you have class or other obligations during that time, you can email me to set up an appointment at another time.
In Comp. 2, our first graded assignment was rough. (Spelling errors counted as significant grammatical errors so I flunked it.) Prof. told everyone who got an F to schedule time to see him.
I did and it was quite helpful. He explained his grading rules, his view on what he wanted, and so on. He pointed out that people like me really need to spell check and use any tools that help. The biggest benefit of that meeting was that we got to a comfortable place to discuss the course material which made in-class discussons actually work.
I suggest something along those lines, then: just tell those below a threshold to come see you.
You might even consider asking the strong students to come by and explain where they are struggling and what kind of backgrounds they have on the topic. In that case, you should just ask every student to come and note their responses. You might discover useful patterns.
Another thing to consider is how to get the strong to help the weak.
In-class discussions or group study can help. That depends on material a bit. In the comp class, prof. had us edit select errors from our submissions as a group and discuss alternatives. An engineering prof. once told us he expected us to work our homework in groups so we should form teams. I normally flew solo, even in classes where hardly anyone did so, but I found a partner immediately after that class session.
Don't underestimate the power of declaring your preferences/expectations.
Sometimes students are intimidated at the idea of going to a teacher during office hours. I think we have all been "cross-examined" during such an experience even though we know it was beneficial.
Instead of inviting them one-on-one perhaps requiring them to come in pairs or small groups would be helpful. This saves a lot of your own time as you work with several students at once. In addition, it removes some of the discomfort of having to go alone to the instructor's office for the students.