This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package app | |
import ij.ImagePlus | |
import imagescience.image.Image | |
import harrislaplace.HarrisLaplace | |
import imagescience.shape.Point | |
import ij.process.ImageProcessor | |
import scalaj.collection.Imports._ | |
object HarrisLaplaceApp extends App { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.Array.canBuildFrom | |
import scala.collection.mutable.ListBuffer | |
import scala.math.random | |
import scalala.library.LinearAlgebra.pinv | |
import scalala.tensor.dense.DenseMatrix | |
import scalala.tensor.dense.DenseVector | |
import scalala.tensor.mutable.Matrix | |
import scalala.tensor.mutable.Vector | |
import scalala.tensor.:: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.Array.canBuildFrom | |
import scala.collection.mutable.ListBuffer | |
import scala.math.random | |
import scalala.library.LinearAlgebra.pinv | |
import scalala.tensor.dense.DenseMatrix | |
import scalala.tensor.dense.DenseVector | |
import scalala.tensor.mutable.Matrix | |
import scalala.tensor.mutable.Vector | |
import scalala.tensor.:: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package imagescience.feature; | |
import imagescience.image.Aspects; | |
import imagescience.image.Axes; | |
import imagescience.image.Coordinates; | |
import imagescience.image.Dimensions; | |
import imagescience.image.FloatImage; | |
import imagescience.image.Image; | |
import imagescience.utility.ImageScience; | |
import imagescience.utility.Messenger; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Models | |
#equipment_specs.rb | |
class EquipmentSpec | |
include Mongoid::Document | |
field :specification, type: String | |
validates :specification, presence: true | |
field :price, type: BigDecimal |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* This program shows how to store tabular data in a 2D array. | |
* | |
* @version 1.40 2004-02-10 | |
* @author Cay Horstmann | |
*/ | |
public class CompoundInterest { | |
public static void main(String[] args) { | |
final double STARTRATE = 10; | |
final int NRATES = 6; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def sentenceAnagrams(sentence: Sentence): List[Sentence] = { | |
def subSentence(occ: Occurrences): List[Sentence] = { | |
if (occ.isEmpty) List(List()) | |
else | |
for { | |
x <- combinations(occ) | |
y <- dictionaryByOccurrences(x) | |
z <- subSentence(subtract(occ, x)) | |
} yield y :: z |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sbt._ | |
import Keys._ | |
import play.Project._ | |
object ApplicationBuild extends Build { | |
val appName = "SubProjectExample" | |
val appVersion = "1.0-SNAPSHOT" | |
val core = Project("core", file("core")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int ans, i; | |
for (i = 1; i < 6; i++) { | |
ans = i % 2; | |
if (ans == 1) | |
System.out.print(i + 1) | |
} | |
int x = 7 + 3 * 6 / 2 - 1; | |
System.out.println(x); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case class ERCForestConf(nbTrees: Int = 8, treeConf: ERCTreeConf = ERCTreeConf()) | |
case class ERCForest(trees: IndexedSeq[ERCTree]) { | |
def assignIndexSeq(pt: Seq[Seq[Float]]): Seq[Int] = { | |
trees.map(_.query(pt)).flatten | |
} | |
def numClusters = trees.map(_.leavesSize).sum | |
} |
OlderNewer