Perfect pitch is a fascinating topic. Sadly, I have to report that my pitch detection capabilities are dreadful. I have always struggled to tune a guitar by ear, luckily this is no longer a required skill because of advancements in technology.
When I was a young child in California I took guitar lessons for a little while and failed miserably at this aspect of the lessons. I had a tuning fork and a standard tuning pitch whistle. I was unable to use either of them and had to resort to using an electronic tuning device that had a mechanical dial on it.
It seems our ability to distinguish between different tones is determined largely by the tones that we are exposed to as a very small child. Apparently, the diversity of tones in my life at this time was small.
The video below, while controversial for some, discusses this topic very well. This gentleman has basically created a perfect pitch child and discusses why it is something that you can only achieve at a very young age.