Implementing symbol layers in Python