Skip to content

Commit

Permalink
Rename to noir_compute 🥹
Browse files Browse the repository at this point in the history
  • Loading branch information
imDema committed Dec 15, 2023
1 parent 44667ac commit aaae20c
Show file tree
Hide file tree
Showing 80 changed files with 280 additions and 286 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[package]
name = "noir"
name = "noir-compute"
description = "Network of Operators In Rust"
version = "0.1.0"
edition = "2021"
authors = [
"Luca De Martini <luca.[email protected]>",
"Luca De Martini <luca.[email protected]>",
"Edoardo Morassutto <[email protected]>",
"Marco Donadoni <[email protected]>"
]
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ The common layout of a Noir program starts with the creation of a `StreamEnviron
#### Wordcount

```rs
use noir::prelude::*;
use noir_compute::prelude::*;

fn main() {
// Convenience method to parse deployment config from CLI arguments
Expand Down Expand Up @@ -58,7 +58,7 @@ fn tokenize(s: &str) -> Vec<String> {


```rs
use noir::prelude::*;
use noir_compute::prelude::*;

fn main() {
// Convenience method to parse deployment config from CLI arguments
Expand Down
8 changes: 4 additions & 4 deletions benches/batch_mode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ use criterion::{black_box, criterion_group, criterion_main, Criterion, Throughpu
use rand::prelude::StdRng;
use rand::{Rng, SeedableRng};

use noir::operator::source::IteratorSource;
use noir::BatchMode;
use noir::EnvironmentConfig;
use noir::StreamEnvironment;
use noir_compute::operator::source::IteratorSource;
use noir_compute::BatchMode;
use noir_compute::EnvironmentConfig;
use noir_compute::StreamEnvironment;

fn batch_mode(batch_mode: BatchMode, dataset: &'static [u32]) {
let config = EnvironmentConfig::local(4);
Expand Down
4 changes: 2 additions & 2 deletions benches/collatz.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use criterion::BenchmarkId;
use criterion::{criterion_group, criterion_main, Criterion, Throughput};
use noir::BatchMode;
use noir::StreamEnvironment;
use noir_compute::BatchMode;
use noir_compute::StreamEnvironment;

mod common;
use common::*;
Expand Down
4 changes: 2 additions & 2 deletions benches/common.rs
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
#![allow(unused)]

use criterion::{black_box, Bencher};
use noir::config::{ExecutionRuntime, RemoteHostConfig, RemoteRuntimeConfig};
use noir_compute::config::{ExecutionRuntime, RemoteHostConfig, RemoteRuntimeConfig};
use std::marker::PhantomData;
use std::sync::atomic::{AtomicU16, Ordering};
use std::sync::Arc;
use std::time::{Duration, Instant};

use noir::*;
use noir_compute::*;

pub const SAMPLES: usize = 50;

Expand Down
8 changes: 4 additions & 4 deletions benches/connected.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
use criterion::BenchmarkId;
use criterion::{criterion_group, criterion_main, Criterion, Throughput};
use fxhash::FxHashMap;
use noir::operator::Operator;
use noir::EnvironmentConfig;
use noir::Stream;
use noir::StreamEnvironment;
use noir_compute::operator::Operator;
use noir_compute::EnvironmentConfig;
use noir_compute::Stream;
use noir_compute::StreamEnvironment;
use rand::prelude::*;
use rand::rngs::SmallRng;
use serde::{Deserialize, Serialize};
Expand Down
8 changes: 4 additions & 4 deletions benches/fold_vs_reduce.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ use criterion::{black_box, criterion_group, criterion_main, Criterion, Throughpu
use rand::prelude::StdRng;
use rand::{Rng, SeedableRng};

use noir::operator::source::IteratorSource;
use noir::BatchMode;
use noir::EnvironmentConfig;
use noir::StreamEnvironment;
use noir_compute::operator::source::IteratorSource;
use noir_compute::BatchMode;
use noir_compute::EnvironmentConfig;
use noir_compute::StreamEnvironment;

fn fold(dataset: &'static [u32]) {
let config = EnvironmentConfig::local(4);
Expand Down
12 changes: 6 additions & 6 deletions benches/nexmark.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
use criterion::{criterion_group, criterion_main, BenchmarkId, Criterion, Throughput};
use nexmark::config::NexmarkConfig;
use noir::operator::window::TransactionOp;
use noir::operator::window::TransactionWindow;
use noir::operator::Operator;
use noir::operator::Timestamp;
use noir::prelude::*;
use noir::Stream;
use noir_compute::operator::window::TransactionOp;
use noir_compute::operator::window::TransactionWindow;
use noir_compute::operator::Operator;
use noir_compute::operator::Timestamp;
use noir_compute::prelude::*;
use noir_compute::Stream;

use nexmark::event::*;

Expand Down
6 changes: 3 additions & 3 deletions benches/shuffle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ use criterion::{black_box, criterion_group, criterion_main, Criterion, Throughpu
use rand::rngs::SmallRng;
use rand::{Rng, SeedableRng};

use noir::operator::source::IteratorSource;
use noir::BatchMode;
use noir::StreamEnvironment;
use noir_compute::operator::source::IteratorSource;
use noir_compute::BatchMode;
use noir_compute::StreamEnvironment;

fn shuffle(dataset: &'static [u32]) {
let mut env = StreamEnvironment::default();
Expand Down
4 changes: 2 additions & 2 deletions benches/wordcount.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ use once_cell::sync::Lazy;
use rand::prelude::StdRng;
use rand::SeedableRng;

use noir::BatchMode;
use noir::StreamEnvironment;
use noir_compute::BatchMode;
use noir_compute::StreamEnvironment;

mod common;
use common::*;
Expand Down
4 changes: 2 additions & 2 deletions examples/car_accidents.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ use std::str::FromStr;
use std::time::Instant;

use itertools::Itertools;
use noir::operator::Operator;
use noir::{prelude::*, Stream};
use noir_compute::operator::Operator;
use noir_compute::{prelude::*, Stream};
use serde::{Deserialize, Serialize};

#[global_allocator]
Expand Down
2 changes: 1 addition & 1 deletion examples/collatz.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use noir::prelude::*;
use noir_compute::prelude::*;
use std::time::Instant;

#[global_allocator]
Expand Down
2 changes: 1 addition & 1 deletion examples/connected_components.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use std::collections::HashSet;
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;
use serde::{Deserialize, Serialize};

#[global_allocator]
Expand Down
2 changes: 1 addition & 1 deletion examples/kmeans.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use std::time::Instant;

use serde::{Deserialize, Serialize};

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
6 changes: 3 additions & 3 deletions examples/logistic_regression.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ fn main() {}
//
// use serde::{Deserialize, Serialize};
//
// use noir::operator::source::CsvSource;
// use noir::EnvironmentConfig;
// use noir::StreamEnvironment;
// use noir_compute::operator::source::CsvSource;
// use noir_compute::EnvironmentConfig;
// use noir_compute::StreamEnvironment;
//
// #[derive(Serialize, Deserialize, Clone, Copy, Debug)]
// struct LabeledPoint {
Expand Down
10 changes: 5 additions & 5 deletions examples/nexmark-latency.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
use clap::Parser;
use nexmark::config::NexmarkConfig;
use noir::operator::Operator;
use noir::operator::Timestamp;
use noir::prelude::*;
use noir::Replication;
use noir::Stream;
use noir_compute::operator::Operator;
use noir_compute::operator::Timestamp;
use noir_compute::prelude::*;
use noir_compute::Replication;
use noir_compute::Stream;
use std::time::Instant;
use std::time::SystemTime;
use std::time::UNIX_EPOCH;
Expand Down
16 changes: 8 additions & 8 deletions examples/nexmark.rs
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
use fxhash::FxHashMap;
use nexmark::config::NexmarkConfig;
use noir::operator::window::TransactionOp;
use noir::operator::window::TransactionWindow;
use noir::operator::ElementGenerator;
use noir::operator::Operator;
use noir::operator::StreamElement;
use noir::operator::Timestamp;
use noir::prelude::*;
use noir::Stream;
use noir_compute::operator::window::TransactionOp;
use noir_compute::operator::window::TransactionWindow;
use noir_compute::operator::ElementGenerator;
use noir_compute::operator::Operator;
use noir_compute::operator::StreamElement;
use noir_compute::operator::Timestamp;
use noir_compute::prelude::*;
use noir_compute::Stream;
use std::cmp::Reverse;
use std::collections::BinaryHeap;
use std::time::Instant;
Expand Down
2 changes: 1 addition & 1 deletion examples/pagerank.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/pagerank_stateful.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use std::mem::replace;
use std::sync::Arc;
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/pagerank_timely.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;
use rand::prelude::*;

#[global_allocator]
Expand Down
2 changes: 1 addition & 1 deletion examples/rolling_top_words.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::time::{Instant, SystemTime};
#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;

use noir::prelude::*;
use noir_compute::prelude::*;
use rand::prelude::*;

const TOPICS: [&str; 50] = [
Expand Down
2 changes: 1 addition & 1 deletion examples/rolling_top_words_e2e.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use std::time::Instant;
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;

use nanorand::Rng;
use noir::prelude::*;
use noir_compute::prelude::*;

const TOPICS: [&str; 50] = [
"#love",
Expand Down
2 changes: 1 addition & 1 deletion examples/simple.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use noir::prelude::*;
use noir_compute::prelude::*;

fn main() {
let (config, _args) = EnvironmentConfig::from_args();
Expand Down
2 changes: 1 addition & 1 deletion examples/transitive_closure.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/triangles_fold.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/triangles_rich_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::time::Instant;

use itertools::Itertools;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/wordcount.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::time::Instant;

use regex::Regex;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/wordcount_assoc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::time::Instant;

use regex::Regex;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/wordcount_opt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::collections::HashMap;
use std::hash::BuildHasherDefault;
use std::time::Instant;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
2 changes: 1 addition & 1 deletion examples/wordcount_windowed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::time::{Duration, Instant};

use regex::Regex;

use noir::prelude::*;
use noir_compute::prelude::*;

#[global_allocator]
static GLOBAL: mimalloc::MiMalloc = mimalloc::MiMalloc;
Expand Down
6 changes: 3 additions & 3 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ pub const CONFIG_ENV_VAR: &str = "NOIR_CONFIG";
/// ## Local environment
///
/// ```
/// # use noir::{StreamEnvironment, EnvironmentConfig};
/// # use noir_compute::{StreamEnvironment, EnvironmentConfig};
/// let config = EnvironmentConfig::local(1);
/// let mut env = StreamEnvironment::new(config);
/// ```
///
/// ## Remote environment
///
/// ```
/// # use noir::{StreamEnvironment, EnvironmentConfig};
/// # use noir_compute::{StreamEnvironment, EnvironmentConfig};
/// # use std::fs::File;
/// # use std::io::Write;
/// let config = r"
Expand All @@ -68,7 +68,7 @@ pub const CONFIG_ENV_VAR: &str = "NOIR_CONFIG";
/// their docs.
///
/// ```no_run
/// # use noir::{EnvironmentConfig, StreamEnvironment};
/// # use noir_compute::{EnvironmentConfig, StreamEnvironment};
/// let (config, args) = EnvironmentConfig::from_args();
/// let mut env = StreamEnvironment::new(config);
/// ```
Expand Down
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The common layout of a Noir program starts with the creation of a `StreamEnviron
#### Wordcount
```no_run
use noir::prelude::*;
use noir_compute::prelude::*;
fn main() {
// Convenience method to parse deployment config from CLI arguments
Expand Down Expand Up @@ -59,7 +59,7 @@ fn tokenize(s: &str) -> Vec<String> {
```no_run
use noir::prelude::*;
use noir_compute::prelude::*;
fn main() {
// Convenience method to parse deployment config from CLI arguments
Expand Down
Loading

0 comments on commit aaae20c

Please sign in to comment.