added initial python impl