Why i getting type mismatch error in spark accumulator?

**hi everyone
I am an amateur in Scala programming language
I received the following error in Scala language , how to solve it ?

indent preformatted text by 4 spaces
   command-2918754276707947:160: error: type mismatch;
   found   : VectorAccumulatorParam.type
   required: org.apache.spark.AccumulatorParam[breeze.linalg.DenseVector[Double]]
   val errors = SC.sc.accumulator(BDV.zeros[Double](numParticles))(VectorAccumulatorParam)
                                                              ^

Thank you for your attention**

indent preformatted text by 4 spaces
    import org.apache.spark.broadcast.Broadcast
    import org.apache.spark.{Accumulator,SparkContext}
    import org.apache.spark.util.AccumulatorV2
    import org.apache.spark.mllib.linalg.Vector
    import breeze.linalg.DenseVector
    import breeze.linalg.{DenseVector=>BDV}
    import breeze.linalg.Vector
    import breeze.linalg.functions.euclideanDistance
    import breeze.linalg._
    import org.apache.log4j.{Level,Logger}
    import org.apache.spark.rdd.RDD

    import scala.util.Random
    import math._
    import scala.collection.mutable.ArrayBuffer
    import org.apache.spark.mllib.clustering.KMeans
    import org.apache.spark.mllib.clustering.BisectingKMeans

    import vegas._
    import vegas.render.WindowRenderer._


   object VectorAccumulatorParam extends AccumulatorV2[BDV[Double],BDV[Double]]{
   def zero(v:BDV[Double]):BDV[Double]=v
   def addInPlace(v1:BDV[Double],v2:BDV[Double]):BDV[Double]= v1 += v2
   }

  **//The following line gives the type error**
  val errors=SC.sc.accumulator(BDV.zeros[Double](numParticles))(VectorAccumulatorParam)


   command-2918754276707947:160: error: type mismatch;
   found   : VectorAccumulatorParam.type
   required: org.apache.spark.AccumulatorParam[breeze.linalg.DenseVector[Double]]
   val errors = SC.sc.accumulator(BDV.zeros[Double](numParticles))(VectorAccumulatorParam)
                                                              ^

My source code is taken from GateHub ->>>>> Apache-Spark-KM-PSO/KMPSO.scala at master · mattsherar/Apache-Spark-KM-PSO · GitHub