It depends on what you mean by "sexually compatible". Attraction, often I know as soon as I see the guy for the first time. Other guys I may not be immediately attracted to, but the attraction grows as I get to know them (Although this can backfire: The Asshole was one of these latter types... first time I saw him I thought he was ugly, then I sort of got to know him and was attracted to what I thought his personality was like, and asked HIM out, then after dating him for a while, I found out he was a sexist, alcoholic asshole!)
As for compatibility for having sex, there are two main parts of this that I can think of, although there are other considerations as well. The two main parts I can think of are size and libido compatibility.
Size: I will know as soon as I have sex with him for the first time, although often I can tell before that when I see what size he is. Now this could work two different ways. Too small and too big. I've never been with a guy who was too big for me, though.
Libido compatibility may take longer to determine, and can also change over time. For example, when my longest term relationship started sexually, we were more compatible. We were definitely size compatible, and somewhat libido compatible although I always did have the higher libido. However, his libido dwindled away to zero after some time, and now it's very difficult. He and I are still friends, but he no longer has any physical libido, and mine is still very high.