Skip to content

Commit 65276b0

Browse files
authored
Merge branch 'main' into benliepert/update_ndarray
2 parents 74a14eb + 191f5fd commit 65276b0

File tree

255 files changed

+4762
-2395
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

255 files changed

+4762
-2395
lines changed

.typos.toml

+1
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ armour = "armor"
3434
artefact = "artifact"
3535
authorise = "authorize"
3636
behaviour = "behavior"
37+
behavioural = "behavioral"
3738
British = "American"
3839
calibre = "caliber"
3940
# allow 'cancelled' since Arrow uses it.

BUILD.md

+3
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ All Rust examples are set up as separate executables, so they can be run by spec
5050
cargo run -p dna
5151
```
5252

53+
They will either connect to an already running rerun viewer, or spawn a new one.
54+
In debug builds, it will spawn `target/debug/rerun` if it exists, otherwise look for `rerun` on `PATH`.
55+
5356

5457
## Building and installing the Rerun Python SDK
5558

Cargo.lock

+48-23
Original file line numberDiff line numberDiff line change
@@ -1777,7 +1777,7 @@ checksum = "68b0cf012f1230e43cd00ebb729c6bb58707ecfa8ad08b52ef3a4ccd2697fc30"
17771777
[[package]]
17781778
name = "ecolor"
17791779
version = "0.28.1"
1780-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1780+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
17811781
dependencies = [
17821782
"bytemuck",
17831783
"emath",
@@ -1787,7 +1787,7 @@ dependencies = [
17871787
[[package]]
17881788
name = "eframe"
17891789
version = "0.28.1"
1790-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1790+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
17911791
dependencies = [
17921792
"ahash",
17931793
"bytemuck",
@@ -1824,7 +1824,7 @@ dependencies = [
18241824
[[package]]
18251825
name = "egui"
18261826
version = "0.28.1"
1827-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1827+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
18281828
dependencies = [
18291829
"accesskit",
18301830
"ahash",
@@ -1841,7 +1841,7 @@ dependencies = [
18411841
[[package]]
18421842
name = "egui-wgpu"
18431843
version = "0.28.1"
1844-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1844+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
18451845
dependencies = [
18461846
"ahash",
18471847
"bytemuck",
@@ -1860,7 +1860,7 @@ dependencies = [
18601860
[[package]]
18611861
name = "egui-winit"
18621862
version = "0.28.1"
1863-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1863+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
18641864
dependencies = [
18651865
"accesskit_winit",
18661866
"ahash",
@@ -1879,30 +1879,28 @@ dependencies = [
18791879
[[package]]
18801880
name = "egui_commonmark"
18811881
version = "0.17.0"
1882-
source = "registry+https://github.com/rust-lang/crates.io-index"
1883-
checksum = "fe88871b75bd43c52a2b44ce5b53160506e7976e239112c56728496d019cc60d"
1882+
source = "git+https://github.com/rerun-io/egui_commonmark?rev=7a9dc755bfa351a3796274cb8ca87129b051c084#7a9dc755bfa351a3796274cb8ca87129b051c084"
18841883
dependencies = [
18851884
"egui",
18861885
"egui_commonmark_backend",
18871886
"egui_extras",
1888-
"pulldown-cmark 0.11.0",
1887+
"pulldown-cmark 0.12.1",
18891888
]
18901889

18911890
[[package]]
18921891
name = "egui_commonmark_backend"
18931892
version = "0.17.0"
1894-
source = "registry+https://github.com/rust-lang/crates.io-index"
1895-
checksum = "148edd9546feba319b16d5a5e551cda46095031ec1e6665e5871eef9ee692967"
1893+
source = "git+https://github.com/rerun-io/egui_commonmark?rev=7a9dc755bfa351a3796274cb8ca87129b051c084#7a9dc755bfa351a3796274cb8ca87129b051c084"
18961894
dependencies = [
18971895
"egui",
18981896
"egui_extras",
1899-
"pulldown-cmark 0.11.0",
1897+
"pulldown-cmark 0.12.1",
19001898
]
19011899

19021900
[[package]]
19031901
name = "egui_extras"
19041902
version = "0.28.1"
1905-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1903+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
19061904
dependencies = [
19071905
"ahash",
19081906
"egui",
@@ -1918,13 +1916,13 @@ dependencies = [
19181916
[[package]]
19191917
name = "egui_glow"
19201918
version = "0.28.1"
1921-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1919+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
19221920
dependencies = [
19231921
"ahash",
19241922
"bytemuck",
19251923
"egui",
19261924
"egui-winit",
1927-
"glow",
1925+
"glow 0.14.0",
19281926
"log",
19291927
"memoffset 0.9.0",
19301928
"puffin",
@@ -1947,7 +1945,7 @@ dependencies = [
19471945
[[package]]
19481946
name = "egui_table"
19491947
version = "0.28.1"
1950-
source = "git+https://github.com/rerun-io/egui_table.git?rev=0f594701d528c4a9553521cb941de1886549dc70#0f594701d528c4a9553521cb941de1886549dc70"
1948+
source = "git+https://github.com/rerun-io/egui_table.git?rev=c76473b244f03a7c67fbbbff9def6fc86c1ca4ea#c76473b244f03a7c67fbbbff9def6fc86c1ca4ea"
19511949
dependencies = [
19521950
"egui",
19531951
"serde",
@@ -1991,7 +1989,7 @@ checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07"
19911989
[[package]]
19921990
name = "emath"
19931991
version = "0.28.1"
1994-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
1992+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
19951993
dependencies = [
19961994
"bytemuck",
19971995
"serde",
@@ -2092,7 +2090,7 @@ dependencies = [
20922090
[[package]]
20932091
name = "epaint"
20942092
version = "0.28.1"
2095-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
2093+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
20962094
dependencies = [
20972095
"ab_glyph",
20982096
"ahash",
@@ -2111,7 +2109,7 @@ dependencies = [
21112109
[[package]]
21122110
name = "epaint_default_fonts"
21132111
version = "0.28.1"
2114-
source = "git+https://github.com/emilk/egui.git?rev=6b7f4312373a301a4cdf7d99a0d546acd34bcd66#6b7f4312373a301a4cdf7d99a0d546acd34bcd66"
2112+
source = "git+https://github.com/emilk/egui.git?rev=e0f0b7f47f4094967530214aec060b9f1ce5954e#e0f0b7f47f4094967530214aec060b9f1ce5954e"
21152113

21162114
[[package]]
21172115
name = "equivalent"
@@ -2550,6 +2548,18 @@ dependencies = [
25502548
"web-sys",
25512549
]
25522550

2551+
[[package]]
2552+
name = "glow"
2553+
version = "0.14.0"
2554+
source = "registry+https://github.com/rust-lang/crates.io-index"
2555+
checksum = "f865cbd94bd355b89611211e49508da98a1fce0ad755c1e8448fb96711b24528"
2556+
dependencies = [
2557+
"js-sys",
2558+
"slotmap",
2559+
"wasm-bindgen",
2560+
"web-sys",
2561+
]
2562+
25532563
[[package]]
25542564
name = "gltf"
25552565
version = "1.4.1"
@@ -3474,7 +3484,7 @@ dependencies = [
34743484
[[package]]
34753485
name = "mp4"
34763486
version = "0.14.0"
3477-
source = "git+https://github.com/rerun-io/mp4?rev=ef529032547d7f97161e95c58bd76856cb116349#ef529032547d7f97161e95c58bd76856cb116349"
3487+
source = "git+https://github.com/rerun-io/mp4?rev=b019fcf3ac8e1befded54728686997cc168117c8#b019fcf3ac8e1befded54728686997cc168117c8"
34783488
dependencies = [
34793489
"byteorder",
34803490
"bytes",
@@ -4526,9 +4536,9 @@ dependencies = [
45264536

45274537
[[package]]
45284538
name = "pulldown-cmark"
4529-
version = "0.11.0"
4539+
version = "0.12.1"
45304540
source = "registry+https://github.com/rust-lang/crates.io-index"
4531-
checksum = "8746739f11d39ce5ad5c2520a9b75285310dbfe78c541ccf832d38615765aec0"
4541+
checksum = "666f0f59e259aea2d72e6012290c09877a780935cc3c18b1ceded41f3890d59c"
45324542
dependencies = [
45334543
"bitflags 2.6.0",
45344544
"memchr",
@@ -4947,7 +4957,6 @@ dependencies = [
49474957
"re_smart_channel",
49484958
"re_tracing",
49494959
"re_types",
4950-
"re_video",
49514960
"thiserror",
49524961
"walkdir",
49534962
]
@@ -5480,6 +5489,7 @@ dependencies = [
54805489
"re_data_ui",
54815490
"re_dataframe",
54825491
"re_entity_db",
5492+
"re_format",
54835493
"re_log",
54845494
"re_log_types",
54855495
"re_renderer",
@@ -5505,6 +5515,7 @@ dependencies = [
55055515
"egui",
55065516
"glam",
55075517
"hexasphere",
5518+
"image",
55085519
"itertools 0.13.0",
55095520
"mimalloc",
55105521
"nohash-hasher",
@@ -5799,8 +5810,10 @@ dependencies = [
57995810
name = "re_video"
58005811
version = "0.19.0-alpha.1+dev"
58015812
dependencies = [
5813+
"itertools 0.13.0",
58025814
"mp4",
58035815
"ordered-float",
5816+
"thiserror",
58045817
]
58055818

58065819
[[package]]
@@ -6156,6 +6169,7 @@ dependencies = [
61566169
"re_arrow2",
61576170
"re_log",
61586171
"re_sdk",
6172+
"re_video",
61596173
]
61606174

61616175
[[package]]
@@ -6180,6 +6194,7 @@ dependencies = [
61806194
"re_log_types",
61816195
"re_memory",
61826196
"re_sdk",
6197+
"re_video",
61836198
"re_web_viewer_server",
61846199
"re_ws_comms",
61856200
"uuid",
@@ -7108,6 +7123,16 @@ dependencies = [
71087123
"rerun",
71097124
]
71107125

7126+
[[package]]
7127+
name = "test_ui_wakeup"
7128+
version = "0.19.0-alpha.1+dev"
7129+
dependencies = [
7130+
"anyhow",
7131+
"clap",
7132+
"re_log",
7133+
"rerun",
7134+
]
7135+
71117136
[[package]]
71127137
name = "thiserror"
71137138
version = "1.0.63"
@@ -7992,7 +8017,7 @@ dependencies = [
79928017
"block",
79938018
"cfg_aliases 0.1.1",
79948019
"core-graphics-types",
7995-
"glow",
8020+
"glow 0.13.1",
79968021
"glutin_wgl_sys",
79978022
"gpu-alloc",
79988023
"gpu-allocator",

Cargo.toml

+9-9
Original file line numberDiff line numberDiff line change
@@ -514,12 +514,12 @@ missing_errors_doc = "allow"
514514
# As a last resport, patch with a commit to our own repository.
515515
# ALWAYS document what PR the commit hash is part of, or when it was merged into the upstream trunk.
516516

517-
ecolor = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
518-
eframe = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
519-
egui = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
520-
egui_extras = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
521-
egui-wgpu = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
522-
emath = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf7d99a0d546acd34bcd66" } # egui master 2024-09-06
517+
ecolor = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
518+
eframe = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
519+
egui = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
520+
egui_extras = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
521+
egui-wgpu = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
522+
emath = { git = "https://github.com/emilk/egui.git", rev = "e0f0b7f47f4094967530214aec060b9f1ce5954e" } # egui master 2024-09-19
523523

524524
# Useful while developing:
525525
# ecolor = { path = "../../egui/crates/ecolor" }
@@ -535,11 +535,11 @@ emath = { git = "https://github.com/emilk/egui.git", rev = "6b7f4312373a301a4cdf
535535
egui_tiles = { git = "https://github.com/rerun-io/egui_tiles", rev = "b2f5e232524deed983bcad01c05f27d0e8b89d98" } # https://github.com/rerun-io/egui_tiles/pull/78 2024-08-28
536536
# egui_tiles = { path = "../egui_tiles" }
537537

538-
# egui_commonmark = { git = "https://github.com/rerun-io/egui_commonmark", rev = "63d5c8933445b9ea9088c4a50b71f4ede1f3c247" } # https://github.com/lampsitter/egui_commonmark/pull/51
538+
egui_commonmark = { git = "https://github.com/rerun-io/egui_commonmark", rev = "7a9dc755bfa351a3796274cb8ca87129b051c084" } # https://github.com/lampsitter/egui_commonmark/pull/65
539539

540540
# commit on `rerun-io/mp4` `main` branch
541-
# https://github.com/rerun-io/mp4/commit/ef529032547d7f97161e95c58bd76856cb116349
542-
mp4 = { git = "https://github.com/rerun-io/mp4", rev = "ef529032547d7f97161e95c58bd76856cb116349" }
541+
# https://github.com/rerun-io/mp4/commit/b019fcf3ac8e1befded54728686997cc168117c8
542+
mp4 = { git = "https://github.com/rerun-io/mp4", rev = "b019fcf3ac8e1befded54728686997cc168117c8" }
543543

544544
# commit on `rerun-io/re_arrow2` `main` branch
545545
# https://github.com/rerun-io/re_arrow2/commit/e4717d6debc6d4474ec10db8f629f823f57bad07

crates/build/re_dev_tools/src/build_examples/snippets.rs

+13-1
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,11 @@ impl Snippets {
3636
let snippet_root = snippets_dir.join("all");
3737
let snippets = collect_snippets_recursively(&snippet_root, &config, &snippet_root)?;
3838

39-
println!("Running {} snippets…", snippets.len());
39+
println!("Download test assets…");
4040
let progress = MultiProgress::new();
41+
download_test_assets(&progress)?;
42+
43+
println!("Running {} snippets…", snippets.len());
4144
let results: Vec<anyhow::Result<PathBuf>> = snippets
4245
.into_par_iter()
4346
.map(|example| example.build(&progress, &self.output_dir))
@@ -190,3 +193,12 @@ struct OptOut {
190193
/// example name -> languages
191194
run: HashMap<String, Vec<String>>,
192195
}
196+
197+
fn download_test_assets(progress: &MultiProgress) -> anyhow::Result<()> {
198+
let download_script = re_build_tools::cargo_metadata()?
199+
.workspace_root
200+
.join("tests/assets/download_test_assets.py");
201+
let mut cmd = Command::new("python3");
202+
cmd.arg(download_script.as_str());
203+
wait_for_output(cmd, "download test assets", progress)
204+
}

crates/build/re_types_builder/src/codegen/cpp/mod.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -1505,7 +1505,13 @@ fn to_arrow_method(
15051505
(
15061506
true,
15071507
quote! {
1508-
return Loggable<#forwarded_type>::to_arrow(&instances->#field_name, num_instances);
1508+
if (num_instances == 0) {
1509+
return Loggable<#forwarded_type>::to_arrow(nullptr, 0);
1510+
} else if (instances == nullptr) {
1511+
return rerun::Error(ErrorCode::UnexpectedNullArgument, "Passed array instances is null when num_elements > 0.");
1512+
} else {
1513+
return Loggable<#forwarded_type>::to_arrow(&instances->#field_name, num_instances);
1514+
}
15091515
},
15101516
)
15111517
} else {

crates/store/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Creates related to storing, indexing, trasmitting, and handling data.
1+
Creates related to storing, indexing, transmitting, and handling data.

crates/store/re_chunk/src/util.rs

+7-11
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ pub fn arrays_to_list_array(
8282
// TODO(cmc): A possible improvement would be to pick the smallest key datatype possible based
8383
// on the cardinality of the input arrays.
8484
pub fn arrays_to_dictionary<Idx: Copy + Eq>(
85-
array_datatype: ArrowDatatype,
85+
array_datatype: &ArrowDatatype,
8686
arrays: &[Option<(Idx, &dyn ArrowArray)>],
8787
) -> Option<ArrowDictionaryArray<i32>> {
8888
// Dedupe the input arrays based on the given primary key.
@@ -115,33 +115,29 @@ pub fn arrays_to_dictionary<Idx: Copy + Eq>(
115115
};
116116

117117
// Concatenate the underlying data as usual, except only the _unique_ values!
118+
// We still need the underlying data to be a list-array, so the dictionary's keys can index
119+
// into this list-array.
118120
let data = if arrays_dense_deduped.is_empty() {
119121
arrow2::array::new_empty_array(array_datatype.clone())
120122
} else {
121-
arrow2::compute::concatenate::concatenate(&arrays_dense_deduped)
123+
let values = arrow2::compute::concatenate::concatenate(&arrays_dense_deduped)
122124
.map_err(|err| {
123125
re_log::warn_once!("failed to concatenate arrays: {err}");
124126
err
125127
})
126-
.ok()?
127-
};
128-
129-
// We still need the underlying data to be a list-array, so the dictionary's keys can index
130-
// into this list-array.
131-
let data = {
132-
let datatype = ArrowListArray::<i32>::default_datatype(array_datatype);
128+
.ok()?;
133129

134130
#[allow(clippy::unwrap_used)] // yes, these are indeed lengths
135131
let offsets =
136132
ArrowOffsets::try_from_lengths(arrays_dense_deduped.iter().map(|array| array.len()))
137133
.unwrap();
138134

139-
ArrowListArray::<i32>::new(datatype, offsets.into(), data, None)
135+
ArrowListArray::<i32>::new(array_datatype.clone(), offsets.into(), values, None).to_boxed()
140136
};
141137

142138
let datatype = ArrowDatatype::Dictionary(
143139
arrow2::datatypes::IntegerType::Int32,
144-
std::sync::Arc::new(data.data_type().clone()),
140+
std::sync::Arc::new(array_datatype.clone()),
145141
true, // is_sorted
146142
);
147143

0 commit comments

Comments
 (0)