Influx Kapacitor : exec format error

kapacitor
#1

run: open server: open service *udf.Service: failed to load process info for "movingAverage": fork/exec /tmp/kapacitor_udf/moving_avg.py: exec format error

I am running the python UDF for kapacitor and get this error. I am following the steps as given here : https://docs.influxdata.com/kapacitor/v1.5/nodes/u_d_f_node/