spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "DeepakVohra (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SPARK-5471) java.lang.NumberFormatException: For input string:
Date Thu, 29 Jan 2015 02:52:34 GMT

    [ https://issues.apache.org/jira/browse/SPARK-5471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14296307#comment-14296307
] 

DeepakVohra commented on SPARK-5471:
------------------------------------

Not a bug. The sample data has to be split at the ,.

>  java.lang.NumberFormatException: For input string: 
> ----------------------------------------------------
>
>                 Key: SPARK-5471
>                 URL: https://issues.apache.org/jira/browse/SPARK-5471
>             Project: Spark
>          Issue Type: New Feature
>    Affects Versions: 1.2.0
>         Environment: Spark 1.2.0 Maven 
>            Reporter: DeepakVohra
>
> Naive Bayes Classifier generates exception with sample_naive_bayes_data.txt
> java.lang.NumberFormatException: For input string: "0,1"
> 	at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1250)
> 	at java.lang.Double.parseDouble(Double.java:540)
> 	at scala.collection.immutable.StringLike$class.toDouble(StringLike.scala:232)
> 	at scala.collection.immutable.StringOps.toDouble(StringOps.scala:31)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:79)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:77)
> 	at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
> 	at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:249)
> 	at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:163)
> 	at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:70)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:228)
> 	at org.apache.spark.rdd.MappedRDD.compute(MappedRDD.scala:31)
> 	at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:263)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:230)
> 	at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61)
> 	at org.apache.spark.scheduler.Task.run(Task.scala:56)
> 	at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:196)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> 	at java.lang.Thread.run(Thread.java:745)
> 15/01/28 21:13:57 WARN TaskSetManager: Lost task 0.0 in stage 0.0 (TID 0, localhost):
java.lang.NumberFormatException: For input string: "0,1"
> 	at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1250)
> 	at java.lang.Double.parseDouble(Double.java:540)
> 	at scala.collection.immutable.StringLike$class.toDouble(StringLike.scala:232)
> 	at scala.collection.immutable.StringOps.toDouble(StringOps.scala:31)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:79)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:77)
> 	at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
> 	at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:249)
> 	at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:163)
> 	at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:70)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:228)
> 	at org.apache.spark.rdd.MappedRDD.compute(MappedRDD.scala:31)
> 	at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:263)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:230)
> 	at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61)
> 	at org.apache.spark.scheduler.Task.run(Task.scala:56)
> 	at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:196)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> 	at java.lang.Thread.run(Thread.java:745)
> 15/01/28 21:13:57 ERROR TaskSetManager: Task 0 in stage 0.0 failed 1 times; aborting
job
> 15/01/28 21:13:57 INFO TaskSchedulerImpl: Removed TaskSet 0.0, whose tasks have all completed,
from pool 
> 15/01/28 21:13:57 INFO TaskSchedulerImpl: Cancelling stage 0
> 15/01/28 21:13:57 INFO DAGScheduler: Job 0 failed: reduce at MLUtils.scala:96, took 1.180869
s
> Exception in thread "main" org.apache.spark.SparkException: Job aborted due to stage
failure: Task 0 in stage 0.0 failed 1 times, most recent failure: Lost task 0.0 in stage 0.0
(TID 0, localhost): java.lang.NumberFormatException: For input string: "0,1"
> 	at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1250)
> 	at java.lang.Double.parseDouble(Double.java:540)
> 	at scala.collection.immutable.StringLike$class.toDouble(StringLike.scala:232)
> 	at scala.collection.immutable.StringOps.toDouble(StringOps.scala:31)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:79)
> 	at org.apache.spark.mllib.util.MLUtils$$anonfun$4.apply(MLUtils.scala:77)
> 	at scala.collection.Iterator$$anon$11.next(Iterator.scala:328)
> 	at org.apache.spark.storage.MemoryStore.unrollSafely(MemoryStore.scala:249)
> 	at org.apache.spark.CacheManager.putInBlockManager(CacheManager.scala:163)
> 	at org.apache.spark.CacheManager.getOrCompute(CacheManager.scala:70)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:228)
> 	at org.apache.spark.rdd.MappedRDD.compute(MappedRDD.scala:31)
> 	at org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:263)
> 	at org.apache.spark.rdd.RDD.iterator(RDD.scala:230)
> 	at org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:61)
> 	at org.apache.spark.scheduler.Task.run(Task.scala:56)
> 	at org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:196)
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
> 	at java.lang.Thread.run(Thread.java:745)
> Driver stacktrace:
> 	at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$failJobAndIndependentStages(DAGScheduler.scala:1214)
> 	at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1203)
> 	at org.apache.spark.scheduler.DAGScheduler$$anonfun$abortStage$1.apply(DAGScheduler.scala:1202)
> 	at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59)
> 	at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47)
> 	at org.apache.spark.scheduler.DAGScheduler.abortStage(DAGScheduler.scala:1202)
> 	at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:696)
> 	at org.apache.spark.scheduler.DAGScheduler$$anonfun$handleTaskSetFailed$1.apply(DAGScheduler.scala:696)
> 	at scala.Option.foreach(Option.scala:236)
> 	at org.apache.spark.scheduler.DAGScheduler.handleTaskSetFailed(DAGScheduler.scala:696)
> 	at org.apache.spark.scheduler.DAGSchedulerEventProcessActor$$anonfun$receive$2.applyOrElse(DAGScheduler.scala:1420)
> 	at akka.actor.Actor$class.aroundReceive(Actor.scala:465)
> 	at org.apache.spark.scheduler.DAGSchedulerEventProcessActor.aroundReceive(DAGScheduler.scala:1375)
> 	at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516)
> 	at akka.actor.ActorCell.invoke(ActorCell.scala:487)
> 	at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238)
> 	at akka.dispatch.Mailbox.run(Mailbox.scala:220)
> 	at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:393)
> 	at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
> 	at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
> 	at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
> 	at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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


Mime
View raw message