Github user HyukjinKwon commented on a diff in the pull request:
https://github.com/apache/spark/pull/18732#discussion_r142591369
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/RelationalGroupedDataset.scala ---
@@ -435,6 +435,33 @@ class RelationalGroupedDataset protected[sql](
df.logicalPlan.output,
df.logicalPlan))
}
+
+ private[sql] def flatMapGroupsInPandas(expr: PythonUDF): DataFrame = {
+ require(expr.vectorized, "Must pass a vectorized python udf")
+
+ val output = expr.dataType match {
+ case s: StructType => s.map {
--- End diff --
little nit (see
https://github.com/databricks/scala-style-guide#pattern-matching):
```scala
case s: StructType => s.map { case StructField(name, dataType,
nullable, metadata) =>
AttributeReference(name, dataType, nullable, metadata)()
}
```
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]