no they cannot. they just look at numbers, quality and movement of the sperm.
that is why most doctors request men to abstain for 3 days prior to a test so that they get more a accurate picture of what his sperm counts/quality are.
They can't tell but if the man did not follow the instructions it can affect the results.