Version 2.2.2
matplotlib

matplotlib.artist.Artist.get_gid

Artist.get_gid()

Returns the group id.