Bill Bradley(great shooter for Princeton U. and the New York Knicks) contributed his knowledge of the game in a book entitled A SENSE OF WHERE YOU ARE.
If you practice and play the game for years, it seems sensible to know that wherever you are on the court, you instinctively know where the basket is.
That is why so many great shooters today don't have to stare at the rim before they shoot. They can grab a pass with their back to the basket, twirl around and shoot, and in it goes. But: practice, practice, practice.