Python Empty Calc Gradient Extension