Albert, the choice of preposition is usually related to the words before, rather than after the preposition. âFar fromâ is a fixed expression. Also, âfromâ usually refers to a physical relationship.
In the second case, we could indeed use âfrom trafficâ, but the meaning would not be exactly the same. In âthe noise of trafficâ, âofâ is not indicating a physical relationship, but merely turning âtrafficâ into a modifier of ânoiseâ â we could also say âthe traffic noiseâ. In fact, I highly recommend my Slavic-speaking students practice using constructions such as âtraffic noiseâ, precisely because it improves their fluency by allowing them not to worry about the preposition.