Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPARK-12746][ML] ArrayType(_, true) should also accept ArrayType(_, false) #10697

Closed
wants to merge 2 commits into from

Conversation

Earthson
Copy link
Contributor

@Earthson Earthson changed the title [ML] ArrayType(_, true) should also accept ArrayType(_, false) [SPARK-12746][ML] ArrayType(_, true) should also accept ArrayType(_, false) Jan 12, 2016
@mengxr
Copy link
Contributor

mengxr commented Feb 12, 2016

ok to test

@@ -71,7 +71,8 @@ private[feature] trait CountVectorizerParams extends Params with HasInputCol wit
/** Validates and transforms the input schema. */
protected def validateAndTransformSchema(schema: StructType): StructType = {
validateParams()
SchemaUtils.checkColumnType(schema, $(inputCol), new ArrayType(StringType, true))
val typeCandidates = List(new ArrayType(StringType, true), new ArrayType(StringType, false))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor: new is not necessary since ArrayType is a case class

@mengxr
Copy link
Contributor

mengxr commented Feb 12, 2016

LGTM pending Jenins

@SparkQA
Copy link

SparkQA commented Feb 12, 2016

Test build #51163 has finished for PR 10697 at commit 9cd7ced.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@asfgit asfgit closed this in 5f1c359 Feb 12, 2016
@mengxr
Copy link
Contributor

mengxr commented Feb 12, 2016

Merged into master. Thanks! @Earthson I didn't merge it into branch-1.6 because checkColumnTypes is not available on branch-1.6. I don't think this is a critical bug for backporting. But if you have time to prepare a PR for branch-1.6, I'm happy to merge it.

@Earthson
Copy link
Contributor Author

@mengxr ok, I'll have a look:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants