better error handling in case of missing sqlalchemy
added variable binning, fromDirectory as dict, fixed isMC
added recursive mkdir -p