BrickPi Version

Is there anyway using Python to tell what version of BrickPi the code is running on?

Could you show a picture of your BrickPi?

I have one of these (2.8.2):


And five of these (S3?):


I meant through the use of code, preferably Python. I want to upload one script to all of my BrickPis that will detect the version and use the appropriate Python library and syntax. It just saves me time uploading the right Python code to the right BrickPi.