sc.makeRDD bug with NumericRange

2014-04-18 Thread Aureliano Buendia
Hi, I just notices that sc.makeRDD() does not make all values given with input type of NumericRange, try this in spark shell: $ MASTER=local[4] bin/spark-shell scala> sc.makeRDD(0.0 to 1 by 0.1).collect().length *8* The expected length is 11. This works correctly when lanching spark with onl

Re: sc.makeRDD bug with NumericRange

2014-04-18 Thread Mark Hamstra
Please file an issue: Spark Project JIRA On Fri, Apr 18, 2014 at 10:25 AM, Aureliano Buendia wrote: > Hi, > > I just notices that sc.makeRDD() does not make all values given with input > type of NumericRange, try this in spark shell: > > > $ MASTER=l

Re: sc.makeRDD bug with NumericRange

2014-04-18 Thread Daniel Darabos
Looks like NumericRange in Scala is just a joke. scala> val x = 0.0 to 1.0 by 0.1 x: scala.collection.immutable.NumericRange[Double] = NumericRange(0.0, 0.1, 0.2, 0.30004, 0.4, 0.5, 0.6, 0.7, 0.7999, 0.8999, 0.) scala> x.take(3) res1: scala.coll

Re: sc.makeRDD bug with NumericRange

2014-04-18 Thread Daniel Darabos
To make up for mocking Scala, I've filed a bug ( https://issues.scala-lang.org/browse/SI-8518) and will try to patch this. On Fri, Apr 18, 2014 at 9:24 PM, Daniel Darabos < daniel.dara...@lynxanalytics.com> wrote: > Looks like NumericRange in Scala is just a joke. > > scala> val x = 0.0 to 1.0 b

Re: sc.makeRDD bug with NumericRange

2014-04-18 Thread Aureliano Buendia
Good catch, Daniel. Looks like this is a scala bug, not a spark one. Yet, spark users got to be careful not using NumericRange. On Fri, Apr 18, 2014 at 9:05 PM, Daniel Darabos < daniel.dara...@lynxanalytics.com> wrote: > To make up for mocking Scala, I've filed a bug ( > https://issues.scala-lan