I am trying to write UDF in Scala and use it in PySpark. So i am wrote simple UDF which takes array>> and must return array