You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "zhengruifeng (Jira)" <ji...@apache.org> on 2021/02/01 02:11:00 UTC

[jira] [Resolved] (SPARK-34256) VectorSlicer refine numFeatures checking and toString method

     [ https://issues.apache.org/jira/browse/SPARK-34256?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

zhengruifeng resolved SPARK-34256.
----------------------------------
    Fix Version/s: 3.2.0
       Resolution: Fixed

Issue resolved by pull request 31354
[https://github.com/apache/spark/pull/31354]

> VectorSlicer refine numFeatures checking and toString method
> ------------------------------------------------------------
>
>                 Key: SPARK-34256
>                 URL: https://issues.apache.org/jira/browse/SPARK-34256
>             Project: Spark
>          Issue Type: Improvement
>          Components: ML
>    Affects Versions: 3.2.0
>            Reporter: zhengruifeng
>            Assignee: zhengruifeng
>            Priority: Trivial
>             Fix For: 3.2.0
>
>
> Current checking of numFeatures needs updates:
> 1, should use inputAttr.size instead of inputAttr.numAttributes to get numFeatures;
> 2, this checking is necessary only if $(indices).nonEmpty, otherwise, $(indices).max will throw exception java.lang.UnsupportedOperationException: empty.max
> 3, in toString, should add length of names;



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org