Link: http://www.guinealynx.info/sexing.html
Many owners and pet stores do not know how to sex guinea pigs. Granted it can be a little difficult to determine when the pups are only a week or so old, but it is imperative you find out who are the boys and girls, as they need to be separated as early as three weeks to prevent future pregnancies.
Small young male pigs have a donut shape to their rectum, totally round or slightly oval, and at the top of this donut, a little dot (sometimes described as an "i"). Girls tend to have a 'Y' shape. A method that has proved successful is to place your finger directly above the opening and push inward and slightly downward, gently but firmly. If absolutely nothing pops out then it is likely to be a female. Determining the gender of a very young guinea pig can be a challenge because their genitals are so small. If you have an opportunity to examine a few pigs, it may be easier to see the differences when you have both sexes to compare.