If a device that was capable of smelling marijuana from miles away existed and was very accurate (could identify houses where the smell was coming from), would police legally be able to use it for the detection of marijuana in a neighborhood?
The relevant case is Kyllo v. US, 533 U.S. 27, where heat emanating from inside the house was detected remotely (without entering the house). The primary question is whether in that case a "search" has occurred. Relying on Katz v. US, 389 U. S. 347 (where sound wave were picked up from outside a telephone booth), there is no search unless the individual manifests a subjective expectation of privacy in the searched object, and society is willing to recognize that expectation as reasonable. "Obtaining by sense-enhancing technology any information regarding the home's interior that could not otherwise have been obtained without physical 'intrusion into a constitutionally protected area' constitutes a search – at least where (as here) the technology in question is not in general public use". In other words, a "search" is not defined in terms of entry into a structure, it is defined in terms of a socially-recognized reasonable expectation of privacy. Accordingly, this magic device conducts searches, which means that a warrant is required.