Ehh, there are effectively equivalent ways of ensuring that you hire X more women without discriminating against men in the interview process.
If you have X people interviewing at your company, you should hire the best person who interviews, no matter the gender.
The REAL way to go about this is to discriminate at the referral/reachout stage.
If you go to your all male engineering team and announce "We are hiring! Refer all your friends!". What you are effectively doing is discriminating against women, because you are going to receive 20 male referrals and 1 women referral. But THIS isn't illegal.
I am suggesting that you do this same but biased towards women referrals, instead of biasing it toward male referrals. You make specific, targeted efforts to get as many women as possible to apply, while not bothering with referral/reachout processes that are likely to receive male heavy applications, and THEN accept the best person who applies to the job, which will almost certainly be a woman, since instead of having a 20male-1female application ratio, you now have a 1male-20female ratio.
One way of ensuring that you get women referrals is to reach out to all of your female engineering friends, and ask THEM for referrals. Or when you are making your job postings, forward it along to the mailing list of all the women in tech meetups, facebook groups, email lists, ect.
I mean, thats what the tech industry is doing right now, but targeted at men, and they never get in trouble for it, even if it is "accidental" that the job postings only get sent to tech groups/meetups that have a 20-1 male to female ratio.