pianoscope is already doing sophisticated classification of partials to tell background sounds from piano tones, but it is not perfect, especially for high pitched sounds. If you are in a very noisy environment, you can always switch off the automatic note detection and change notes manually. This will improve noise resiliency a lot.