added working visualization code from other repository