All Projects → libmir → Mir Algorithm

libmir / Mir Algorithm

Licence: other
Dlang Core Library

Programming Languages

d
599 projects

Projects that are alternatives of or similar to Mir Algorithm

Easyiterator
🏃 Iterators made easy! Zero cost abstractions for designing and using C++ iterators.
Stars: ✭ 107 (-25.17%)
Mutual labels:  algorithms, iterator, range
staticstep
Provides truly zero-cost alternatives to Iterator::step_by for both incrementing and decrementing any type that satisfies RangeBounds<T: Copy + Default + Step>.
Stars: ✭ 13 (-90.91%)
Mutual labels:  iterator, range
Range V3
Range library for C++14/17/20, basis for C++20's std::ranges
Stars: ✭ 3,231 (+2159.44%)
Mutual labels:  iterator, range
Functionalplus
Functional Programming Library for C++. Write concise and readable C++ code.
Stars: ✭ 1,286 (+799.3%)
Mutual labels:  algorithms, range
Data Structures
Common data structures and algorithms implemented in JavaScript
Stars: ✭ 139 (-2.8%)
Mutual labels:  algorithms
Reconnoitre
A security tool for multithreaded information gathering and service enumeration whilst building directory structures to store results, along with writing out recommendations for further testing.
Stars: ✭ 1,824 (+1175.52%)
Mutual labels:  range
Conduit
High Performance Streams Based on Coroutine TS ⚡
Stars: ✭ 135 (-5.59%)
Mutual labels:  algorithms
Moment Precise Range
A moment.js plugin to display human-readable date/time ranges
Stars: ✭ 134 (-6.29%)
Mutual labels:  range
Coding Problems
Solutions for various coding/algorithmic problems and many useful resources for learning algorithms and data structures
Stars: ✭ 2,221 (+1453.15%)
Mutual labels:  algorithms
Interviews
A list of fancy questions I've been asked during the interviews I had. Some of them I ask when interviewing people.
Stars: ✭ 140 (-2.1%)
Mutual labels:  algorithms
Leetcode Patterns
A curated list of leetcode questions grouped by their common patterns
Stars: ✭ 3,750 (+2522.38%)
Mutual labels:  algorithms
Important Java Concepts
🚀 Complete Java - A to Z ║ 📚 Notes and Programs of all Important Concepts of Java - OOPS, Data Structures, Algorithms, Design Patterns & Development + Kotlin + Android 🔥
Stars: ✭ 135 (-5.59%)
Mutual labels:  algorithms
Thermite
Thermite SIMD: Melt your CPU
Stars: ✭ 141 (-1.4%)
Mutual labels:  algorithms
Datastructures Algorithms
The best library for implementation of all Data Structures and Algorithms - Trees + Graph Algorithms too!
Stars: ✭ 2,105 (+1372.03%)
Mutual labels:  algorithms
Hptt
High-Performance Tensor Transpose library
Stars: ✭ 141 (-1.4%)
Mutual labels:  multidimensional-arrays
Keras Rl2
Reinforcement learning with tensorflow 2 keras
Stars: ✭ 134 (-6.29%)
Mutual labels:  algorithms
Placement Preparation
Hello everyone, I have created this repository specifically for competitive questions and for placements preparation.
Stars: ✭ 137 (-4.2%)
Mutual labels:  algorithms
19 udacity dsa
Data Structures & Algorithms Nanodegree Program from Udacity
Stars: ✭ 140 (-2.1%)
Mutual labels:  algorithms
Dsa Geeksclasses
DSA-Self Paced With Doubt Assistance Course Solutions in Python (Python 3)
Stars: ✭ 137 (-4.2%)
Mutual labels:  algorithms
Algorithms
STL Algorithm Cheat Sheet + example code from STL Algorithm Video Series.
Stars: ✭ 136 (-4.9%)
Mutual labels:  algorithms

codecov.io Build Status Circle CI

Dub downloads Dub downloads License Latest version Bountysource

Mir Algorithm

API Documentation

Blogs

Mir Type System for .NET

Example (3 sec)

/+dub.sdl:
dependency "mir-algorithm" version="~>2.0.0"
+/

void main()
{
    import mir.ndslice;

    auto matrix = slice!double(3, 4);
    matrix[] = 0;
    matrix.diagonal[] = 1;

    auto row = matrix[2];
    row[3] = 6;
    assert(matrix[2, 3] == 6); // D & C index order
    
    import std.stdio;
    matrix.writeln; // [[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 6]]
}

Open on run.dlang.io

Example (30 sec)

/+dub.sdl:
dependency "mir-algorithm" version="~>2.0.0"
+/
void main()
{
    import mir.ndslice;
    import std.stdio : writefln;

    enum fmt = "%(%(%.2f %)\n%)\n";

    // Magic sqaure. 
    // `a` is lazy, each element is computed on-demand.
    auto a = magic(5).as!float;
    writefln(fmt, a);

    // 5x5 grid on sqaure [1, 2] x [0, 1] with values x * x + y. 
    // `b` is lazy, each element is computed on-demand.
    auto b = linspace!float([5, 5], [1f, 2f], [0f, 1f]).map!"a * a + b";
    writefln(fmt, b);

    // allocate a 5 x 5 contiguous matrix
    auto c = slice!float(5, 5);

    c[] = transposed(a + b / 2); // no memory allocations here
    // 1. b / 2 - lazy element-wise operation with scalars
    // 2. a + (...) - lazy element-wise operation with other slices
    // Both slices must be `contiguous` or one-dimensional.
    // 3. transposed(...) - trasposes matrix view. The result is `universal` (numpy-like) matrix.
    // 5. c[] = (...) -- performs element-wise assignment.
    writefln(fmt, c);
}

Open on run.dlang.io

Our sponsors

       

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].