Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
/mirPublic

Mir (backports): Sparse tensors, Hoffman

License

NotificationsYou must be signed in to change notification settings

libmir/mir

Repository files navigation

The last Mir version with old ndslice isv0.22.1.

❗️ Mir GLAS was moved tohttps://github.com/libmir/mir-glas.

Dub downloadsLicenseBountysourceLatest versioncodecov.ioCircle CI

Mir

Generic Numerical Library for Science and Machine Learning.

Separated Mir Projects
  • Mir Algorithm - Multidimensional arrays (ndslice), iterators, algorithms.
  • Mir Random - Professional Random Number Generators
  • Mir GLAS - Linear Algebra Library (Experimental, not supported for now)
  • Mir BLAS - Bindings to libraries with CBLAS API like OpenBLAS and Intel MKL.
  • Mir LAPACK - Bindings to libraries with LAPACK API like OpenBLAS and Intel MKL.
  • MirOptim - Nonlinear Solvers.
  • Mir CPUID - CPU Identification routines (less buggy then Phobos).

Documentation

Documentation API can be foundhere.

Contents

  • mir.glas - Generic Linear Algebra Subroutines
  • mir.sparse Sparse Tensors
  • Sparse - DOK format
  • Different ranges for COO format
  • CompressedTensor - CSR/CSC formats
  • mir.sparse.blas - Sparse BLAS forCompressedTensor
  • mir.model.lda.hoffman - Online variational Bayes for latent Dirichlet allocation (Online VB LDA) for sparse documents. LDA is used for topic modeling.
  • mir.combinatorics Combinations, combinations with repeats, cartesian power, permutations.

Compatibility

LinuxMac OS XWindows
64-bitBuild StatusBuild StatusBuild status
32-bitBuild StatusN/AN/A

Example

/+dub.sdl:dependency "mir" version="~>3.1.0"+/importstd.stdio;import mir.combinatorics;voidmain(string[] args){    writeln([1,2].combinations);}

Fast setup with the dub package manager

Latest version

Dub is the D's package manager.You can create a new project with:

dub init <project-name>

Now you need to edit thedub.json addmir as dependency.

{..."dependencies": {"mir":"~><current-version>"},"dflags-ldc": ["-mcpu=native"]}

Now you can create anapp.d file in thesource folder and run your code with

dub --compiler=ldmd2

Flag--build=release and can be added for a performance boost:

dub --compiler=ldmd2 --build=release

ldmd2 is a shell on top ofLDC (LLVM D Compiler).

"dflags-ldc": ["-mcpu=native"] allows LDC to optimize Mir for your CPU.

Contributing

See ourTODO List.Mir is very young and we are open for contributing to source code, documentation, examples and benchmarks.


[8]ページ先頭

©2009-2025 Movatter.jp