Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate legacy Points{2|3}D and all their components #2768

Merged
merged 37 commits into from
Jul 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
05b3f89
codegen
teh-cmc Jul 21, 2023
3db5887
fmt
teh-cmc Jul 21, 2023
76b7cc4
turn Point2D into LegacyPoint2D, and expose new Point2D in its stead
teh-cmc Jul 20, 2023
1b034ad
use new Point2D component all the way through for Rust stuff
teh-cmc Jul 20, 2023
27dbb18
migrate all arrow store internal testing to new Point2D
teh-cmc Jul 20, 2023
b3fc43f
use new Point2D component all the way through for Python stuff
teh-cmc Jul 20, 2023
7b8e374
impl LegacyComponent for new Point2D
teh-cmc Jul 21, 2023
ab4036f
entirely getting rid of legacy Point2D
teh-cmc Jul 21, 2023
0370645
annihilated legacy Point3D
teh-cmc Jul 21, 2023
15bfddb
don't rely on deprecated re_components pkg re-exporting stuff from th…
teh-cmc Jul 21, 2023
871953d
fully rewrite legacy log_point(s) in terms of Points{2|3}D
teh-cmc Jul 21, 2023
a0fc954
annihilate legacy DrawOrder
teh-cmc Jul 21, 2023
5e5f66a
deprecate legacy Label
teh-cmc Jul 21, 2023
b29ae56
annihilate legacy Radius
teh-cmc Jul 21, 2023
6c37632
deprecate legacy Color (probably part 1 of N)
teh-cmc Jul 21, 2023
93099e1
annihilate legacy ClassId (as much as humanly possible)
teh-cmc Jul 24, 2023
5fdeea3
annihilate legacy KeypointId (as much as humanly possible)
teh-cmc Jul 24, 2023
aac9d9a
fmt
teh-cmc Jul 24, 2023
13fc33d
annihilate legacy Label (as much as humanly possible)
teh-cmc Jul 24, 2023
c31ea5b
annihilate legacy Color (as much as humanly possible)
teh-cmc Jul 24, 2023
5eae134
TODO hunting
teh-cmc Jul 24, 2023
236ca13
legacy log_points' positions parameter is now mandatory
teh-cmc Jul 24, 2023
1c92257
fmt
teh-cmc Jul 24, 2023
68bffa6
lints
teh-cmc Jul 24, 2023
1cf35c6
doc fixes
teh-cmc Jul 24, 2023
e00367a
codegen
teh-cmc Jul 25, 2023
9b77baf
annihilate legacy InstanceKey (+ fix rebase mess)
teh-cmc Jul 25, 2023
9e530cf
rebase shenanigans
teh-cmc Jul 26, 2023
caeba12
update Rust docs: ColorRGBA -> Color
teh-cmc Jul 26, 2023
9c10884
lints
teh-cmc Jul 26, 2023
af7f674
codegen
teh-cmc Jul 26, 2023
39a1831
datatype checking should only apply to logical types until migration …
teh-cmc Jul 26, 2023
0d6bff5
self-rebase shenanigans
teh-cmc Jul 26, 2023
30d6d90
log_any -> log
teh-cmc Jul 27, 2023
2170814
lints
teh-cmc Jul 28, 2023
4507d81
expose Loggable in re_sdk too
teh-cmc Jul 28, 2023
d0f296f
lints
teh-cmc Jul 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions Cargo.lock

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

7 changes: 5 additions & 2 deletions crates/re_arrow_store/benches/arrow2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,13 @@ use criterion::{criterion_group, Criterion};
use itertools::Itertools;
use re_components::{
datagen::{build_some_instances, build_some_point2d, build_some_rects},
Point2D, Rect2D,
Rect2D,
};
use re_log_types::{DataCell, SizeBytes as _};
use re_types::{components::InstanceKey, Component};
use re_types::{
components::{InstanceKey, Point2D},
Component,
};

// ---

Expand Down
7 changes: 5 additions & 2 deletions crates/re_arrow_store/examples/latest_component.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,13 @@ use re_arrow_store::polars_util::latest_component;
use re_arrow_store::{test_row, DataStore, LatestAtQuery, TimeType, Timeline};
use re_components::{
datagen::{build_frame_nr, build_some_point2d, build_some_rects},
Point2D, Rect2D,
Rect2D,
};
use re_log_types::EntityPath;
use re_types::{components::InstanceKey, Loggable};
use re_types::{
components::{InstanceKey, Point2D},
Loggable,
};

fn main() {
let mut store = DataStore::new(InstanceKey::name(), Default::default());
Expand Down
7 changes: 5 additions & 2 deletions crates/re_arrow_store/examples/latest_components.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,13 @@ use re_arrow_store::polars_util::latest_components;
use re_arrow_store::{test_row, DataStore, LatestAtQuery, TimeType, Timeline};
use re_components::{
datagen::{build_frame_nr, build_some_point2d, build_some_rects},
Point2D, Rect2D,
Rect2D,
};
use re_log_types::EntityPath;
use re_types::{components::InstanceKey, Loggable};
use re_types::{
components::{InstanceKey, Point2D},
Loggable,
};

fn main() {
let mut store = DataStore::new(InstanceKey::name(), Default::default());
Expand Down
7 changes: 5 additions & 2 deletions crates/re_arrow_store/examples/range_components.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,13 @@ use polars_core::prelude::JoinType;
use re_arrow_store::{polars_util, test_row, DataStore, RangeQuery, TimeRange};
use re_components::{
datagen::{build_frame_nr, build_some_point2d, build_some_rects},
Point2D, Rect2D,
Rect2D,
};
use re_log_types::{EntityPath, TimeType, Timeline};
use re_types::{components::InstanceKey, Loggable};
use re_types::{
components::{InstanceKey, Point2D},
Loggable as _,
};

fn main() {
let mut store = DataStore::new(InstanceKey::name(), Default::default());
Expand Down
10 changes: 7 additions & 3 deletions crates/re_arrow_store/src/store_write.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,15 @@ impl DataStore {
use std::collections::hash_map::Entry;
match self.type_registry.entry(cell.component_name()) {
Entry::Occupied(entry) => {
if entry.get() != cell.datatype() {
// NOTE: Don't care about extensions until the migration is over (arrow2-convert
// issues).
let expected = entry.get().to_logical_type().clone();
let got = cell.datatype().to_logical_type().clone();
if expected != got {
return Err(WriteError::TypeCheck {
component: cell.component_name(),
expected: entry.get().clone(),
got: cell.datatype().clone(),
expected,
got,
});
}
}
Expand Down
8 changes: 4 additions & 4 deletions crates/re_arrow_store/tests/correctness.rs
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ fn range_join_across_single_row_impl(store: &mut DataStore) {
prelude::{DataFrame, JoinType},
series::Series,
};
use re_components::{ColorRGBA, Point2D};
use re_types::components::{Color, Point2D};

let ent_path = EntityPath::from("this/that");

Expand All @@ -232,7 +232,7 @@ fn range_join_across_single_row_impl(store: &mut DataStore) {
timeline_frame_nr,
re_arrow_store::TimeRange::new(i64::MIN.into(), i64::MAX.into()),
);
let components = [InstanceKey::name(), Point2D::name(), ColorRGBA::name()];
let components = [InstanceKey::name(), Point2D::name(), Color::name()];
let dfs = re_arrow_store::polars_util::range_components(
store,
&query,
Expand All @@ -247,12 +247,12 @@ fn range_join_across_single_row_impl(store: &mut DataStore) {
let instances =
InstanceKey::to_arrow(vec![InstanceKey(0), InstanceKey(1), InstanceKey(2)], None);
let points = Point2D::to_arrow(points, None);
let colors = ColorRGBA::to_arrow(colors, None);
let colors = Color::to_arrow(colors, None);

DataFrame::new(vec![
Series::try_from((InstanceKey::name().as_ref(), instances)).unwrap(),
Series::try_from((Point2D::name().as_ref(), points)).unwrap(),
Series::try_from((ColorRGBA::name().as_ref(), colors)).unwrap(),
Series::try_from((Color::name().as_ref(), colors)).unwrap(),
])
.unwrap()
};
Expand Down
Loading