
geotrellis.spark.io.index.KeyIndexMethod.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of geotrellis-spark_2.11 Show documentation
Show all versions of geotrellis-spark_2.11 Show documentation
GeoTrellis is an open source geographic data processing engine for high performance applications.
The newest version!
package geotrellis.spark.io.index
import geotrellis.spark._
trait KeyIndexMethod[K] extends Serializable {
/** Helper method to get the resolution of a dimension. Takes the ceiling. */
def resolution(max: Double, min: Double): Int = {
val length = max - min + 1
math.ceil(scala.math.log(length) / scala.math.log(2)).toInt
}
def createIndex(keyBounds: KeyBounds[K]): KeyIndex[K]
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy