def read_input():
 images = []
 for line in sys.stdin:
  line = line.strip()
  line = line.strip('[]')
  items = line.split()
  images.extend(items)
 return images

def read_input ( ) : images = [ ] for line in sys . stdin : line = line . strip ( ) line = line . strip ( '[]' ) items = line . split ( ) images . extend ( items ) return images
read a value from a gpio .