diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index abaa65b1725b..1f07bcdb65ff 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -209,7 +209,8 @@ Update instructions: | Crate | Description | |--------------------|--------------------------------------------------------------------------------------| | re_analytics | Rerun's analytics SDK | -| re_capabilities | Capability tokens | +| re_byte_size | Calculate the heap-allocated size of values at runtime | +| re_capabilities | Capability tokens | | re_case | Case conversions, the way Rerun likes them | | re_crash_handler | Detect panics and signals, logging them and optionally sending them to analytics. | | re_error | Helpers for handling errors. | diff --git a/Cargo.lock b/Cargo.lock index 356aea98c0b7..cc5951d3b51d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -5605,6 +5605,17 @@ dependencies = [ "walkdir", ] +[[package]] +name = "re_byte_size" +version = "0.22.0-alpha.1+dev" +dependencies = [ + "arrow", + "half", + "re_arrow2", + "re_tuid", + "smallvec", +] + [[package]] name = "re_capabilities" version = "0.22.0-alpha.1+dev" @@ -5637,6 +5648,7 @@ dependencies = [ "nohash-hasher", "rand", "re_arrow2", + "re_byte_size", "re_error", "re_format", "re_format_arrow", @@ -5667,6 +5679,7 @@ dependencies = [ "parking_lot", "rand", "re_arrow2", + "re_byte_size", "re_chunk", "re_format", "re_log", @@ -5689,6 +5702,7 @@ dependencies = [ "egui", "egui_extras", "itertools 0.13.0", + "re_byte_size", "re_chunk_store", "re_format", "re_log_types", @@ -5708,6 +5722,7 @@ dependencies = [ "egui_plot", "itertools 0.13.0", "nohash-hasher", + "re_byte_size", "re_data_source", "re_data_ui", "re_format", @@ -5814,6 +5829,7 @@ dependencies = [ "image", "itertools 0.13.0", "nohash-hasher", + "re_byte_size", "re_capabilities", "re_chunk_store", "re_entity_db", @@ -5897,6 +5913,7 @@ dependencies = [ "parking_lot", "rand", "re_build_info", + "re_byte_size", "re_chunk", "re_chunk_store", "re_format", @@ -6033,6 +6050,7 @@ dependencies = [ "num-traits", "re_arrow2", "re_build_info", + "re_byte_size", "re_format", "re_log", "re_protos", @@ -6133,6 +6151,7 @@ dependencies = [ "paste", "rand", "re_arrow2", + "re_byte_size", "re_chunk", "re_chunk_store", "re_error", @@ -6264,6 +6283,7 @@ dependencies = [ "re_arrow2", "re_build_info", "re_build_tools", + "re_byte_size", "re_chunk", "re_chunk_store", "re_data_loader", @@ -6428,6 +6448,7 @@ dependencies = [ "rayon", "re_arrow2", "re_build_tools", + "re_byte_size", "re_format", "re_log", "re_log_types", @@ -6484,18 +6505,17 @@ dependencies = [ "bytemuck", "criterion", "document-features", - "half", "itertools 0.13.0", "nohash-hasher", "once_cell", "re_arrow2", + "re_byte_size", "re_case", "re_error", "re_string_interner", "re_tracing", "re_tuid", "serde", - "smallvec", "thiserror 1.0.65", ] @@ -7203,6 +7223,7 @@ dependencies = [ "re_analytics", "re_build_info", "re_build_tools", + "re_byte_size", "re_capabilities", "re_chunk", "re_chunk_store", diff --git a/Cargo.toml b/Cargo.toml index 3b001f0d8032..5079054fede6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -80,6 +80,7 @@ re_format = { path = "crates/utils/re_format", version = "=0.22.0-alpha.1", defa re_int_histogram = { path = "crates/utils/re_int_histogram", version = "=0.22.0-alpha.1", default-features = false } re_log = { path = "crates/utils/re_log", version = "=0.22.0-alpha.1", default-features = false } re_memory = { path = "crates/utils/re_memory", version = "=0.22.0-alpha.1", default-features = false } +re_byte_size = { path = "crates/utils/re_byte_size", version = "=0.22.0-alpha.1", default-features = false } re_smart_channel = { path = "crates/utils/re_smart_channel", version = "=0.22.0-alpha.1", default-features = false } re_string_interner = { path = "crates/utils/re_string_interner", version = "=0.22.0-alpha.1", default-features = false } re_tracing = { path = "crates/utils/re_tracing", version = "=0.22.0-alpha.1", default-features = false } diff --git a/crates/build/re_types_builder/src/codegen/rust/api.rs b/crates/build/re_types_builder/src/codegen/rust/api.rs index 058dce7b7a89..3c33171b8068 100644 --- a/crates/build/re_types_builder/src/codegen/rust/api.rs +++ b/crates/build/re_types_builder/src/codegen/rust/api.rs @@ -331,7 +331,7 @@ fn quote_struct( }; quote! { - impl ::re_types_core::SizeBytes for #name { + impl ::re_byte_size::SizeBytes for #name { #[inline] fn heap_size_bytes(&self) -> u64 { #heap_size_bytes_impl @@ -443,7 +443,7 @@ fn quote_union( }; quote! { - impl ::re_types_core::SizeBytes for #name { + impl ::re_byte_size::SizeBytes for #name { #[inline] fn heap_size_bytes(&self) -> u64 { #![allow(clippy::match_same_arms)] @@ -630,7 +630,7 @@ fn quote_enum( } } - impl ::re_types_core::SizeBytes for #name { + impl ::re_byte_size::SizeBytes for #name { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_chunk/Cargo.toml b/crates/store/re_chunk/Cargo.toml index 676a0d1ddbab..90e253be49dc 100644 --- a/crates/store/re_chunk/Cargo.toml +++ b/crates/store/re_chunk/Cargo.toml @@ -37,6 +37,7 @@ arrow = ["arrow2/arrow"] [dependencies] # Rerun +re_byte_size.workspace = true re_error.workspace = true re_format.workspace = true re_format_arrow.workspace = true diff --git a/crates/store/re_chunk/src/batcher.rs b/crates/store/re_chunk/src/batcher.rs index cefbaeed9a42..44a9ffe6be70 100644 --- a/crates/store/re_chunk/src/batcher.rs +++ b/crates/store/re_chunk/src/batcher.rs @@ -8,8 +8,9 @@ use arrow2::array::{Array as Arrow2Array, PrimitiveArray as Arrow2PrimitiveArray use crossbeam::channel::{Receiver, Sender}; use nohash_hasher::IntMap; +use re_byte_size::SizeBytes as _; use re_log_types::{EntityPath, ResolvedTimeRange, TimeInt, TimePoint, Timeline}; -use re_types_core::{ComponentDescriptor, SizeBytes as _}; +use re_types_core::ComponentDescriptor; use crate::{chunk::ChunkComponents, Chunk, ChunkId, ChunkResult, RowId, TimeColumn}; @@ -695,7 +696,7 @@ impl PendingRow { } } -impl re_types_core::SizeBytes for PendingRow { +impl re_byte_size::SizeBytes for PendingRow { #[inline] fn heap_size_bytes(&self) -> u64 { let Self { diff --git a/crates/store/re_chunk/src/chunk.rs b/crates/store/re_chunk/src/chunk.rs index 25ace6e31545..ca2605d97dd4 100644 --- a/crates/store/re_chunk/src/chunk.rs +++ b/crates/store/re_chunk/src/chunk.rs @@ -8,14 +8,14 @@ use arrow2::{ }, Either, }; - use itertools::{izip, Itertools}; use nohash_hasher::IntMap; +use re_byte_size::SizeBytes as _; use re_log_types::{EntityPath, ResolvedTimeRange, Time, TimeInt, TimePoint, Timeline}; use re_types_core::{ ComponentDescriptor, ComponentName, DeserializationError, Loggable, LoggableBatch, - SerializationError, SizeBytes, + SerializationError, }; use crate::{ChunkId, RowId}; @@ -1399,7 +1399,7 @@ impl TimeColumn { } } -impl re_types_core::SizeBytes for Chunk { +impl re_byte_size::SizeBytes for Chunk { #[inline] fn heap_size_bytes(&self) -> u64 { let Self { @@ -1428,7 +1428,7 @@ impl re_types_core::SizeBytes for Chunk { } } -impl re_types_core::SizeBytes for TimeColumn { +impl re_byte_size::SizeBytes for TimeColumn { #[inline] fn heap_size_bytes(&self) -> u64 { let Self { diff --git a/crates/store/re_chunk/src/helpers.rs b/crates/store/re_chunk/src/helpers.rs index 4e1ac8ddaf5b..8045e5af5289 100644 --- a/crates/store/re_chunk/src/helpers.rs +++ b/crates/store/re_chunk/src/helpers.rs @@ -4,7 +4,7 @@ use arrow::array::ArrayRef; use arrow2::array::Array as Arrow2Array; use re_log_types::{TimeInt, Timeline}; -use re_types_core::{Component, ComponentName, SizeBytes}; +use re_types_core::{Component, ComponentName}; use crate::{Chunk, ChunkResult, RowId}; @@ -175,7 +175,7 @@ impl std::ops::Deref for UnitChunkShared { } } -impl SizeBytes for UnitChunkShared { +impl re_byte_size::SizeBytes for UnitChunkShared { #[inline] fn heap_size_bytes(&self) -> u64 { Chunk::heap_size_bytes(&self.0) diff --git a/crates/store/re_chunk/src/id.rs b/crates/store/re_chunk/src/id.rs index 1ac286d4e74e..3fe38ba7eb12 100644 --- a/crates/store/re_chunk/src/id.rs +++ b/crates/store/re_chunk/src/id.rs @@ -86,7 +86,7 @@ impl ChunkId { } } -impl re_types_core::SizeBytes for ChunkId { +impl re_byte_size::SizeBytes for ChunkId { #[inline] fn heap_size_bytes(&self) -> u64 { 0 @@ -223,7 +223,7 @@ impl RowId { } } -impl re_types_core::SizeBytes for RowId { +impl re_byte_size::SizeBytes for RowId { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_chunk/src/lib.rs b/crates/store/re_chunk/src/lib.rs index 564885c20101..9ee2ed555e18 100644 --- a/crates/store/re_chunk/src/lib.rs +++ b/crates/store/re_chunk/src/lib.rs @@ -52,6 +52,7 @@ pub mod external { pub use arrow2; pub use nohash_hasher; + pub use re_byte_size; pub use re_log_types; #[cfg(not(target_arch = "wasm32"))] diff --git a/crates/store/re_chunk/src/transport.rs b/crates/store/re_chunk/src/transport.rs index 874ba3034ff9..c7bf9d52559e 100644 --- a/crates/store/re_chunk/src/transport.rs +++ b/crates/store/re_chunk/src/transport.rs @@ -9,11 +9,12 @@ use arrow2::{ Schema as Arrow2Schema, TimeUnit as ArrowTimeUnit, }, }; - use itertools::Itertools; use nohash_hasher::IntMap; + +use re_byte_size::SizeBytes as _; use re_log_types::{EntityPath, Timeline}; -use re_types_core::{Component as _, ComponentDescriptor, Loggable as _, SizeBytes}; +use re_types_core::{Component as _, ComponentDescriptor, Loggable as _}; use crate::{chunk::ChunkComponents, Chunk, ChunkError, ChunkId, ChunkResult, RowId, TimeColumn}; diff --git a/crates/store/re_chunk_store/Cargo.toml b/crates/store/re_chunk_store/Cargo.toml index dde2529fa031..1929c5c73989 100644 --- a/crates/store/re_chunk_store/Cargo.toml +++ b/crates/store/re_chunk_store/Cargo.toml @@ -27,6 +27,7 @@ deadlock_detection = ["parking_lot/deadlock_detection"] [dependencies] # Rerun dependencies: +re_byte_size.workspace = true re_chunk.workspace = true re_format.workspace = true re_log = { workspace = true, features = ["setup"] } diff --git a/crates/store/re_chunk_store/src/gc.rs b/crates/store/re_chunk_store/src/gc.rs index f6f7612cb27f..72fffcb0868a 100644 --- a/crates/store/re_chunk_store/src/gc.rs +++ b/crates/store/re_chunk_store/src/gc.rs @@ -5,11 +5,12 @@ use std::{ use ahash::{HashMap, HashSet}; use nohash_hasher::IntMap; +use re_byte_size::SizeBytes; use web_time::Instant; use re_chunk::{Chunk, ChunkId}; use re_log_types::{EntityPath, ResolvedTimeRange, TimeInt, Timeline}; -use re_types_core::{ComponentName, SizeBytes}; +use re_types_core::ComponentName; use crate::{ store::ChunkIdSetPerTime, ChunkStore, ChunkStoreChunkStats, ChunkStoreDiff, ChunkStoreDiffKind, diff --git a/crates/store/re_chunk_store/src/stats.rs b/crates/store/re_chunk_store/src/stats.rs index 213d946b9b23..2562ebc7acbc 100644 --- a/crates/store/re_chunk_store/src/stats.rs +++ b/crates/store/re_chunk_store/src/stats.rs @@ -1,7 +1,7 @@ use std::sync::{atomic::Ordering, Arc}; +use re_byte_size::SizeBytes; use re_chunk::{Chunk, ComponentName, EntityPath, Timeline}; -use re_types_core::SizeBytes; use crate::ChunkStore; diff --git a/crates/store/re_chunk_store/src/writes.rs b/crates/store/re_chunk_store/src/writes.rs index 28546832796c..19d14ad72b85 100644 --- a/crates/store/re_chunk_store/src/writes.rs +++ b/crates/store/re_chunk_store/src/writes.rs @@ -4,8 +4,8 @@ use ahash::HashMap; use arrow2::array::{Array as _, ListArray as Arrow2ListArray}; use itertools::Itertools as _; +use re_byte_size::SizeBytes; use re_chunk::{Chunk, EntityPath, RowId}; -use re_types_core::SizeBytes; use crate::{ store::ChunkIdSetPerTime, ChunkStore, ChunkStoreChunkStats, ChunkStoreConfig, ChunkStoreDiff, diff --git a/crates/store/re_entity_db/Cargo.toml b/crates/store/re_entity_db/Cargo.toml index 9b2f6e326543..3cbc5cccaa05 100644 --- a/crates/store/re_entity_db/Cargo.toml +++ b/crates/store/re_entity_db/Cargo.toml @@ -28,6 +28,7 @@ serde = ["dep:serde", "re_log_types/serde"] [dependencies] re_build_info.workspace = true +re_byte_size.workspace = true re_chunk = { workspace = true, features = ["serde"] } re_chunk_store.workspace = true re_format.workspace = true diff --git a/crates/store/re_entity_db/src/entity_db.rs b/crates/store/re_entity_db/src/entity_db.rs index 0d2563d557e5..618332b18d40 100644 --- a/crates/store/re_entity_db/src/entity_db.rs +++ b/crates/store/re_entity_db/src/entity_db.rs @@ -761,7 +761,7 @@ impl EntityDb { } } -impl re_types_core::SizeBytes for EntityDb { +impl re_byte_size::SizeBytes for EntityDb { #[inline] fn heap_size_bytes(&self) -> u64 { // TODO(emilk): size of entire EntityDb, including secondary indices etc diff --git a/crates/store/re_log_types/Cargo.toml b/crates/store/re_log_types/Cargo.toml index 58c67788ff93..8e13bf3a3e12 100644 --- a/crates/store/re_log_types/Cargo.toml +++ b/crates/store/re_log_types/Cargo.toml @@ -43,6 +43,7 @@ serde = [ # Rerun re_build_info.workspace = true +re_byte_size.workspace = true re_format.workspace = true re_log.workspace = true re_protos.workspace = true diff --git a/crates/store/re_log_types/src/example_components.rs b/crates/store/re_log_types/src/example_components.rs index 5ee3df3a3a81..849d88385493 100644 --- a/crates/store/re_log_types/src/example_components.rs +++ b/crates/store/re_log_types/src/example_components.rs @@ -2,7 +2,8 @@ use std::sync::Arc; -use re_types_core::{Component, ComponentDescriptor, DeserializationError, Loggable, SizeBytes}; +use re_byte_size::SizeBytes; +use re_types_core::{Component, ComponentDescriptor, DeserializationError, Loggable}; // ---------------------------------------------------------------------------- diff --git a/crates/store/re_log_types/src/hash.rs b/crates/store/re_log_types/src/hash.rs index 93826b76edee..6920b376f4d1 100644 --- a/crates/store/re_log_types/src/hash.rs +++ b/crates/store/re_log_types/src/hash.rs @@ -7,7 +7,7 @@ #[derive(Copy, Clone, Eq, PartialOrd, Ord)] pub struct Hash64(u64); -impl re_types_core::SizeBytes for Hash64 { +impl re_byte_size::SizeBytes for Hash64 { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_log_types/src/path/entity_path.rs b/crates/store/re_log_types/src/path/entity_path.rs index ea412cf364cf..77d2cdc2a9a3 100644 --- a/crates/store/re_log_types/src/path/entity_path.rs +++ b/crates/store/re_log_types/src/path/entity_path.rs @@ -3,8 +3,8 @@ use std::sync::Arc; use ahash::{HashMap, HashSet}; use itertools::Itertools as _; +use re_byte_size::SizeBytes; use re_string_interner::InternedString; -use re_types_core::SizeBytes; use crate::{hash::Hash64, EntityPathPart}; @@ -14,7 +14,7 @@ use crate::{hash::Hash64, EntityPathPart}; #[derive(Copy, Clone, Eq, PartialOrd, Ord)] pub struct EntityPathHash(Hash64); -impl re_types_core::SizeBytes for EntityPathHash { +impl re_byte_size::SizeBytes for EntityPathHash { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_log_types/src/resolved_time_range.rs b/crates/store/re_log_types/src/resolved_time_range.rs index 5cd8af4a561c..56d8fadcae05 100644 --- a/crates/store/re_log_types/src/resolved_time_range.rs +++ b/crates/store/re_log_types/src/resolved_time_range.rs @@ -125,7 +125,7 @@ impl ResolvedTimeRange { } } -impl re_types_core::SizeBytes for ResolvedTimeRange { +impl re_byte_size::SizeBytes for ResolvedTimeRange { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_log_types/src/time_point/mod.rs b/crates/store/re_log_types/src/time_point/mod.rs index dbb5ea5bda21..696da3d8cc42 100644 --- a/crates/store/re_log_types/src/time_point/mod.rs +++ b/crates/store/re_log_types/src/time_point/mod.rs @@ -98,7 +98,7 @@ impl TimePoint { } } -impl re_types_core::SizeBytes for TimePoint { +impl re_byte_size::SizeBytes for TimePoint { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_log_types/src/time_point/time_int.rs b/crates/store/re_log_types/src/time_point/time_int.rs index 46e73dca4721..807869f74aaf 100644 --- a/crates/store/re_log_types/src/time_point/time_int.rs +++ b/crates/store/re_log_types/src/time_point/time_int.rs @@ -12,7 +12,7 @@ pub struct TimeInt(Option); static_assertions::assert_eq_size!(TimeInt, i64); static_assertions::assert_eq_align!(TimeInt, i64); -impl re_types_core::SizeBytes for TimeInt { +impl re_byte_size::SizeBytes for TimeInt { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_log_types/src/time_point/timeline.rs b/crates/store/re_log_types/src/time_point/timeline.rs index da8f723115d9..d428b23d4176 100644 --- a/crates/store/re_log_types/src/time_point/timeline.rs +++ b/crates/store/re_log_types/src/time_point/timeline.rs @@ -125,7 +125,7 @@ impl Timeline { impl nohash_hasher::IsEnabled for Timeline {} -impl re_types_core::SizeBytes for Timeline { +impl re_byte_size::SizeBytes for Timeline { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_query/Cargo.toml b/crates/store/re_query/Cargo.toml index c99ad2a87247..389d3e749ff5 100644 --- a/crates/store/re_query/Cargo.toml +++ b/crates/store/re_query/Cargo.toml @@ -28,6 +28,7 @@ codegen = [] [dependencies] # Rerun dependencies: +re_byte_size.workspace = true re_chunk.workspace = true re_chunk_store.workspace = true re_error.workspace = true diff --git a/crates/store/re_query/src/cache.rs b/crates/store/re_query/src/cache.rs index a6e7edf16492..44444152524c 100644 --- a/crates/store/re_query/src/cache.rs +++ b/crates/store/re_query/src/cache.rs @@ -26,7 +26,7 @@ pub struct QueryCacheKey { pub component_name: ComponentName, } -impl re_types_core::SizeBytes for QueryCacheKey { +impl re_byte_size::SizeBytes for QueryCacheKey { #[inline] fn heap_size_bytes(&self) -> u64 { let Self { diff --git a/crates/store/re_query/src/cache_stats.rs b/crates/store/re_query/src/cache_stats.rs index 7eb8a96c0daa..e34506a815e4 100644 --- a/crates/store/re_query/src/cache_stats.rs +++ b/crates/store/re_query/src/cache_stats.rs @@ -1,6 +1,6 @@ use std::collections::BTreeMap; -use re_types_core::SizeBytes as _; +use re_byte_size::SizeBytes as _; use crate::{QueryCache, QueryCacheKey}; diff --git a/crates/store/re_query/src/latest_at.rs b/crates/store/re_query/src/latest_at.rs index 2bca910b2d12..eb0afd78425d 100644 --- a/crates/store/re_query/src/latest_at.rs +++ b/crates/store/re_query/src/latest_at.rs @@ -8,12 +8,13 @@ use arrow2::array::Array as Arrow2Array; use nohash_hasher::IntMap; use parking_lot::RwLock; +use re_byte_size::SizeBytes; use re_chunk::{Chunk, RowId, UnitChunkShared}; use re_chunk_store::{ChunkStore, LatestAtQuery, TimeInt}; use re_log_types::EntityPath; use re_types_core::{ components::ClearIsRecursive, external::arrow::array::ArrayRef, Component, ComponentDescriptor, - ComponentName, SizeBytes, + ComponentName, }; use crate::{QueryCache, QueryCacheKey, QueryError}; diff --git a/crates/store/re_query/src/range.rs b/crates/store/re_query/src/range.rs index 6680b61c6d98..2b91f1a3a7f1 100644 --- a/crates/store/re_query/src/range.rs +++ b/crates/store/re_query/src/range.rs @@ -4,10 +4,11 @@ use ahash::HashMap; use nohash_hasher::IntMap; use parking_lot::RwLock; +use re_byte_size::SizeBytes; use re_chunk::{Chunk, ChunkId}; use re_chunk_store::{ChunkStore, RangeQuery, TimeInt}; use re_log_types::{EntityPath, ResolvedTimeRange}; -use re_types_core::{ComponentDescriptor, ComponentName, DeserializationError, SizeBytes}; +use re_types_core::{ComponentDescriptor, ComponentName, DeserializationError}; use crate::{QueryCache, QueryCacheKey}; diff --git a/crates/store/re_types/Cargo.toml b/crates/store/re_types/Cargo.toml index 46a740e3d6b6..b6c2250dcad0 100644 --- a/crates/store/re_types/Cargo.toml +++ b/crates/store/re_types/Cargo.toml @@ -52,6 +52,7 @@ testing = [] [dependencies] # Rerun +re_byte_size.workspace = true re_format.workspace = true re_log.workspace = true re_log_types.workspace = true diff --git a/crates/store/re_types/src/archetypes/annotation_context.rs b/crates/store/re_types/src/archetypes/annotation_context.rs index 8612d3af7624..4f75eb79e6f8 100644 --- a/crates/store/re_types/src/archetypes/annotation_context.rs +++ b/crates/store/re_types/src/archetypes/annotation_context.rs @@ -221,7 +221,7 @@ impl AnnotationContext { } } -impl ::re_types_core::SizeBytes for AnnotationContext { +impl ::re_byte_size::SizeBytes for AnnotationContext { #[inline] fn heap_size_bytes(&self) -> u64 { self.context.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/arrows2d.rs b/crates/store/re_types/src/archetypes/arrows2d.rs index 73d077994f4f..65c1454a13b2 100644 --- a/crates/store/re_types/src/archetypes/arrows2d.rs +++ b/crates/store/re_types/src/archetypes/arrows2d.rs @@ -566,7 +566,7 @@ impl Arrows2D { } } -impl ::re_types_core::SizeBytes for Arrows2D { +impl ::re_byte_size::SizeBytes for Arrows2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.vectors.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/arrows3d.rs b/crates/store/re_types/src/archetypes/arrows3d.rs index a6cd1074b5c3..9f4c648b479d 100644 --- a/crates/store/re_types/src/archetypes/arrows3d.rs +++ b/crates/store/re_types/src/archetypes/arrows3d.rs @@ -532,7 +532,7 @@ impl Arrows3D { } } -impl ::re_types_core::SizeBytes for Arrows3D { +impl ::re_byte_size::SizeBytes for Arrows3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.vectors.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/asset3d.rs b/crates/store/re_types/src/archetypes/asset3d.rs index e1381ac13f03..46de56856857 100644 --- a/crates/store/re_types/src/archetypes/asset3d.rs +++ b/crates/store/re_types/src/archetypes/asset3d.rs @@ -325,7 +325,7 @@ impl Asset3D { } } -impl ::re_types_core::SizeBytes for Asset3D { +impl ::re_byte_size::SizeBytes for Asset3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.blob.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/asset_video.rs b/crates/store/re_types/src/archetypes/asset_video.rs index 6d405894be12..3bc3494f7f82 100644 --- a/crates/store/re_types/src/archetypes/asset_video.rs +++ b/crates/store/re_types/src/archetypes/asset_video.rs @@ -332,7 +332,7 @@ impl AssetVideo { } } -impl ::re_types_core::SizeBytes for AssetVideo { +impl ::re_byte_size::SizeBytes for AssetVideo { #[inline] fn heap_size_bytes(&self) -> u64 { self.blob.heap_size_bytes() + self.media_type.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/bar_chart.rs b/crates/store/re_types/src/archetypes/bar_chart.rs index 8f5e2157db79..a0a72808d8f5 100644 --- a/crates/store/re_types/src/archetypes/bar_chart.rs +++ b/crates/store/re_types/src/archetypes/bar_chart.rs @@ -241,7 +241,7 @@ impl BarChart { } } -impl ::re_types_core::SizeBytes for BarChart { +impl ::re_byte_size::SizeBytes for BarChart { #[inline] fn heap_size_bytes(&self) -> u64 { self.values.heap_size_bytes() + self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/boxes2d.rs b/crates/store/re_types/src/archetypes/boxes2d.rs index e63a42357d97..4af433bf4e84 100644 --- a/crates/store/re_types/src/archetypes/boxes2d.rs +++ b/crates/store/re_types/src/archetypes/boxes2d.rs @@ -556,7 +556,7 @@ impl Boxes2D { } } -impl ::re_types_core::SizeBytes for Boxes2D { +impl ::re_byte_size::SizeBytes for Boxes2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.half_sizes.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/boxes3d.rs b/crates/store/re_types/src/archetypes/boxes3d.rs index f0b2d929212e..b9a3773fdb4f 100644 --- a/crates/store/re_types/src/archetypes/boxes3d.rs +++ b/crates/store/re_types/src/archetypes/boxes3d.rs @@ -689,7 +689,7 @@ impl Boxes3D { } } -impl ::re_types_core::SizeBytes for Boxes3D { +impl ::re_byte_size::SizeBytes for Boxes3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.half_sizes.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/capsules3d.rs b/crates/store/re_types/src/archetypes/capsules3d.rs index 7e5cb90368b7..f35d06ba6b40 100644 --- a/crates/store/re_types/src/archetypes/capsules3d.rs +++ b/crates/store/re_types/src/archetypes/capsules3d.rs @@ -639,7 +639,7 @@ impl Capsules3D { } } -impl ::re_types_core::SizeBytes for Capsules3D { +impl ::re_byte_size::SizeBytes for Capsules3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.lengths.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/depth_image.rs b/crates/store/re_types/src/archetypes/depth_image.rs index fcaa8f20b1b7..9ad9d9e9d341 100644 --- a/crates/store/re_types/src/archetypes/depth_image.rs +++ b/crates/store/re_types/src/archetypes/depth_image.rs @@ -538,7 +538,7 @@ impl DepthImage { } } -impl ::re_types_core::SizeBytes for DepthImage { +impl ::re_byte_size::SizeBytes for DepthImage { #[inline] fn heap_size_bytes(&self) -> u64 { self.buffer.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/disconnected_space.rs b/crates/store/re_types/src/archetypes/disconnected_space.rs index 642694071edc..7fd70ca34985 100644 --- a/crates/store/re_types/src/archetypes/disconnected_space.rs +++ b/crates/store/re_types/src/archetypes/disconnected_space.rs @@ -219,7 +219,7 @@ impl DisconnectedSpace { } } -impl ::re_types_core::SizeBytes for DisconnectedSpace { +impl ::re_byte_size::SizeBytes for DisconnectedSpace { #[inline] fn heap_size_bytes(&self) -> u64 { self.disconnected_space.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/ellipsoids3d.rs b/crates/store/re_types/src/archetypes/ellipsoids3d.rs index 034fbb9f6047..f489375d5c7e 100644 --- a/crates/store/re_types/src/archetypes/ellipsoids3d.rs +++ b/crates/store/re_types/src/archetypes/ellipsoids3d.rs @@ -701,7 +701,7 @@ impl Ellipsoids3D { } } -impl ::re_types_core::SizeBytes for Ellipsoids3D { +impl ::re_byte_size::SizeBytes for Ellipsoids3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.half_sizes.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/encoded_image.rs b/crates/store/re_types/src/archetypes/encoded_image.rs index c415be42a437..3d44789d062a 100644 --- a/crates/store/re_types/src/archetypes/encoded_image.rs +++ b/crates/store/re_types/src/archetypes/encoded_image.rs @@ -350,7 +350,7 @@ impl EncodedImage { } } -impl ::re_types_core::SizeBytes for EncodedImage { +impl ::re_byte_size::SizeBytes for EncodedImage { #[inline] fn heap_size_bytes(&self) -> u64 { self.blob.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/geo_line_strings.rs b/crates/store/re_types/src/archetypes/geo_line_strings.rs index 341616ee2eb3..483d08e56823 100644 --- a/crates/store/re_types/src/archetypes/geo_line_strings.rs +++ b/crates/store/re_types/src/archetypes/geo_line_strings.rs @@ -315,7 +315,7 @@ impl GeoLineStrings { } } -impl ::re_types_core::SizeBytes for GeoLineStrings { +impl ::re_byte_size::SizeBytes for GeoLineStrings { #[inline] fn heap_size_bytes(&self) -> u64 { self.line_strings.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/geo_points.rs b/crates/store/re_types/src/archetypes/geo_points.rs index 1051801f5767..1fab69253378 100644 --- a/crates/store/re_types/src/archetypes/geo_points.rs +++ b/crates/store/re_types/src/archetypes/geo_points.rs @@ -359,7 +359,7 @@ impl GeoPoints { } } -impl ::re_types_core::SizeBytes for GeoPoints { +impl ::re_byte_size::SizeBytes for GeoPoints { #[inline] fn heap_size_bytes(&self) -> u64 { self.positions.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/graph_edges.rs b/crates/store/re_types/src/archetypes/graph_edges.rs index 19fa08c8c526..1da88a3858d7 100644 --- a/crates/store/re_types/src/archetypes/graph_edges.rs +++ b/crates/store/re_types/src/archetypes/graph_edges.rs @@ -250,7 +250,7 @@ impl GraphEdges { } } -impl ::re_types_core::SizeBytes for GraphEdges { +impl ::re_byte_size::SizeBytes for GraphEdges { #[inline] fn heap_size_bytes(&self) -> u64 { self.edges.heap_size_bytes() + self.graph_type.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/graph_nodes.rs b/crates/store/re_types/src/archetypes/graph_nodes.rs index 5931330051f3..57fb6e8deb6d 100644 --- a/crates/store/re_types/src/archetypes/graph_nodes.rs +++ b/crates/store/re_types/src/archetypes/graph_nodes.rs @@ -449,7 +449,7 @@ impl GraphNodes { } } -impl ::re_types_core::SizeBytes for GraphNodes { +impl ::re_byte_size::SizeBytes for GraphNodes { #[inline] fn heap_size_bytes(&self) -> u64 { self.node_ids.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/image.rs b/crates/store/re_types/src/archetypes/image.rs index 523f26001142..e13118acd7bf 100644 --- a/crates/store/re_types/src/archetypes/image.rs +++ b/crates/store/re_types/src/archetypes/image.rs @@ -420,7 +420,7 @@ impl Image { } } -impl ::re_types_core::SizeBytes for Image { +impl ::re_byte_size::SizeBytes for Image { #[inline] fn heap_size_bytes(&self) -> u64 { self.buffer.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/instance_poses3d.rs b/crates/store/re_types/src/archetypes/instance_poses3d.rs index fd99a27f18ea..7467c753a2e0 100644 --- a/crates/store/re_types/src/archetypes/instance_poses3d.rs +++ b/crates/store/re_types/src/archetypes/instance_poses3d.rs @@ -460,7 +460,7 @@ impl InstancePoses3D { } } -impl ::re_types_core::SizeBytes for InstancePoses3D { +impl ::re_byte_size::SizeBytes for InstancePoses3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.translations.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/line_strips2d.rs b/crates/store/re_types/src/archetypes/line_strips2d.rs index 657ffd47d1e3..751634cad3aa 100644 --- a/crates/store/re_types/src/archetypes/line_strips2d.rs +++ b/crates/store/re_types/src/archetypes/line_strips2d.rs @@ -544,7 +544,7 @@ impl LineStrips2D { } } -impl ::re_types_core::SizeBytes for LineStrips2D { +impl ::re_byte_size::SizeBytes for LineStrips2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.strips.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/line_strips3d.rs b/crates/store/re_types/src/archetypes/line_strips3d.rs index 3bca90b8753f..271ba62a3ae1 100644 --- a/crates/store/re_types/src/archetypes/line_strips3d.rs +++ b/crates/store/re_types/src/archetypes/line_strips3d.rs @@ -510,7 +510,7 @@ impl LineStrips3D { } } -impl ::re_types_core::SizeBytes for LineStrips3D { +impl ::re_byte_size::SizeBytes for LineStrips3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.strips.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/mesh3d.rs b/crates/store/re_types/src/archetypes/mesh3d.rs index e4a7d8528a09..b9db13fd2c3b 100644 --- a/crates/store/re_types/src/archetypes/mesh3d.rs +++ b/crates/store/re_types/src/archetypes/mesh3d.rs @@ -670,7 +670,7 @@ impl Mesh3D { } } -impl ::re_types_core::SizeBytes for Mesh3D { +impl ::re_byte_size::SizeBytes for Mesh3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.vertex_positions.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/pinhole.rs b/crates/store/re_types/src/archetypes/pinhole.rs index 23dc3ee1c755..faa547daf0e5 100644 --- a/crates/store/re_types/src/archetypes/pinhole.rs +++ b/crates/store/re_types/src/archetypes/pinhole.rs @@ -452,7 +452,7 @@ impl Pinhole { } } -impl ::re_types_core::SizeBytes for Pinhole { +impl ::re_byte_size::SizeBytes for Pinhole { #[inline] fn heap_size_bytes(&self) -> u64 { self.image_from_camera.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/points2d.rs b/crates/store/re_types/src/archetypes/points2d.rs index 8b8cbf318a53..f9fbf0736ae0 100644 --- a/crates/store/re_types/src/archetypes/points2d.rs +++ b/crates/store/re_types/src/archetypes/points2d.rs @@ -618,7 +618,7 @@ impl Points2D { } } -impl ::re_types_core::SizeBytes for Points2D { +impl ::re_byte_size::SizeBytes for Points2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.positions.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/points3d.rs b/crates/store/re_types/src/archetypes/points3d.rs index 0828e9e0eda4..eb73be1becd2 100644 --- a/crates/store/re_types/src/archetypes/points3d.rs +++ b/crates/store/re_types/src/archetypes/points3d.rs @@ -569,7 +569,7 @@ impl Points3D { } } -impl ::re_types_core::SizeBytes for Points3D { +impl ::re_byte_size::SizeBytes for Points3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.positions.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/scalar.rs b/crates/store/re_types/src/archetypes/scalar.rs index 8bebaac4327a..fc33ed040c89 100644 --- a/crates/store/re_types/src/archetypes/scalar.rs +++ b/crates/store/re_types/src/archetypes/scalar.rs @@ -205,7 +205,7 @@ impl Scalar { } } -impl ::re_types_core::SizeBytes for Scalar { +impl ::re_byte_size::SizeBytes for Scalar { #[inline] fn heap_size_bytes(&self) -> u64 { self.scalar.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/segmentation_image.rs b/crates/store/re_types/src/archetypes/segmentation_image.rs index b26145d93c44..bb708752d312 100644 --- a/crates/store/re_types/src/archetypes/segmentation_image.rs +++ b/crates/store/re_types/src/archetypes/segmentation_image.rs @@ -358,7 +358,7 @@ impl SegmentationImage { } } -impl ::re_types_core::SizeBytes for SegmentationImage { +impl ::re_byte_size::SizeBytes for SegmentationImage { #[inline] fn heap_size_bytes(&self) -> u64 { self.buffer.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/series_line.rs b/crates/store/re_types/src/archetypes/series_line.rs index 258b7bd9996c..3762871076f2 100644 --- a/crates/store/re_types/src/archetypes/series_line.rs +++ b/crates/store/re_types/src/archetypes/series_line.rs @@ -373,7 +373,7 @@ impl SeriesLine { } } -impl ::re_types_core::SizeBytes for SeriesLine { +impl ::re_byte_size::SizeBytes for SeriesLine { #[inline] fn heap_size_bytes(&self) -> u64 { self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/series_point.rs b/crates/store/re_types/src/archetypes/series_point.rs index b77a9c91b18b..d835e4fde0c6 100644 --- a/crates/store/re_types/src/archetypes/series_point.rs +++ b/crates/store/re_types/src/archetypes/series_point.rs @@ -366,7 +366,7 @@ impl SeriesPoint { } } -impl ::re_types_core::SizeBytes for SeriesPoint { +impl ::re_byte_size::SizeBytes for SeriesPoint { #[inline] fn heap_size_bytes(&self) -> u64 { self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/tensor.rs b/crates/store/re_types/src/archetypes/tensor.rs index 54abbdffd86c..e233b9e422ed 100644 --- a/crates/store/re_types/src/archetypes/tensor.rs +++ b/crates/store/re_types/src/archetypes/tensor.rs @@ -266,7 +266,7 @@ impl Tensor { } } -impl ::re_types_core::SizeBytes for Tensor { +impl ::re_byte_size::SizeBytes for Tensor { #[inline] fn heap_size_bytes(&self) -> u64 { self.data.heap_size_bytes() + self.value_range.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/text_document.rs b/crates/store/re_types/src/archetypes/text_document.rs index 06d506570baf..dec85a289692 100644 --- a/crates/store/re_types/src/archetypes/text_document.rs +++ b/crates/store/re_types/src/archetypes/text_document.rs @@ -294,7 +294,7 @@ impl TextDocument { } } -impl ::re_types_core::SizeBytes for TextDocument { +impl ::re_byte_size::SizeBytes for TextDocument { #[inline] fn heap_size_bytes(&self) -> u64 { self.text.heap_size_bytes() + self.media_type.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/text_log.rs b/crates/store/re_types/src/archetypes/text_log.rs index c23408094261..83283fde7bc3 100644 --- a/crates/store/re_types/src/archetypes/text_log.rs +++ b/crates/store/re_types/src/archetypes/text_log.rs @@ -301,7 +301,7 @@ impl TextLog { } } -impl ::re_types_core::SizeBytes for TextLog { +impl ::re_byte_size::SizeBytes for TextLog { #[inline] fn heap_size_bytes(&self) -> u64 { self.text.heap_size_bytes() + self.level.heap_size_bytes() + self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/transform3d.rs b/crates/store/re_types/src/archetypes/transform3d.rs index 81eeef4990e0..61d162935f9b 100644 --- a/crates/store/re_types/src/archetypes/transform3d.rs +++ b/crates/store/re_types/src/archetypes/transform3d.rs @@ -595,7 +595,7 @@ impl Transform3D { } } -impl ::re_types_core::SizeBytes for Transform3D { +impl ::re_byte_size::SizeBytes for Transform3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.translation.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/video_frame_reference.rs b/crates/store/re_types/src/archetypes/video_frame_reference.rs index e302867c0531..4078de5748b6 100644 --- a/crates/store/re_types/src/archetypes/video_frame_reference.rs +++ b/crates/store/re_types/src/archetypes/video_frame_reference.rs @@ -348,7 +348,7 @@ impl VideoFrameReference { } } -impl ::re_types_core::SizeBytes for VideoFrameReference { +impl ::re_byte_size::SizeBytes for VideoFrameReference { #[inline] fn heap_size_bytes(&self) -> u64 { self.timestamp.heap_size_bytes() + self.video_reference.heap_size_bytes() diff --git a/crates/store/re_types/src/archetypes/view_coordinates.rs b/crates/store/re_types/src/archetypes/view_coordinates.rs index 4007da4f52f6..886809015878 100644 --- a/crates/store/re_types/src/archetypes/view_coordinates.rs +++ b/crates/store/re_types/src/archetypes/view_coordinates.rs @@ -210,7 +210,7 @@ impl ViewCoordinates { } } -impl ::re_types_core::SizeBytes for ViewCoordinates { +impl ::re_byte_size::SizeBytes for ViewCoordinates { #[inline] fn heap_size_bytes(&self) -> u64 { self.xyz.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/background.rs b/crates/store/re_types/src/blueprint/archetypes/background.rs index 0b56c276a7e5..c3121132fd02 100644 --- a/crates/store/re_types/src/blueprint/archetypes/background.rs +++ b/crates/store/re_types/src/blueprint/archetypes/background.rs @@ -214,7 +214,7 @@ impl Background { } } -impl ::re_types_core::SizeBytes for Background { +impl ::re_byte_size::SizeBytes for Background { #[inline] fn heap_size_bytes(&self) -> u64 { self.kind.heap_size_bytes() + self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/container_blueprint.rs b/crates/store/re_types/src/blueprint/archetypes/container_blueprint.rs index 2971a46e1150..7ee586ef0a22 100644 --- a/crates/store/re_types/src/blueprint/archetypes/container_blueprint.rs +++ b/crates/store/re_types/src/blueprint/archetypes/container_blueprint.rs @@ -545,7 +545,7 @@ impl ContainerBlueprint { } } -impl ::re_types_core::SizeBytes for ContainerBlueprint { +impl ::re_byte_size::SizeBytes for ContainerBlueprint { #[inline] fn heap_size_bytes(&self) -> u64 { self.container_kind.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/dataframe_query.rs b/crates/store/re_types/src/blueprint/archetypes/dataframe_query.rs index 22044c2a31ed..3655711f06d0 100644 --- a/crates/store/re_types/src/blueprint/archetypes/dataframe_query.rs +++ b/crates/store/re_types/src/blueprint/archetypes/dataframe_query.rs @@ -380,7 +380,7 @@ impl DataframeQuery { } } -impl ::re_types_core::SizeBytes for DataframeQuery { +impl ::re_byte_size::SizeBytes for DataframeQuery { #[inline] fn heap_size_bytes(&self) -> u64 { self.timeline.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/force_center.rs b/crates/store/re_types/src/blueprint/archetypes/force_center.rs index 5f12962b42dc..7ef849a0276f 100644 --- a/crates/store/re_types/src/blueprint/archetypes/force_center.rs +++ b/crates/store/re_types/src/blueprint/archetypes/force_center.rs @@ -232,7 +232,7 @@ impl ForceCenter { } } -impl ::re_types_core::SizeBytes for ForceCenter { +impl ::re_byte_size::SizeBytes for ForceCenter { #[inline] fn heap_size_bytes(&self) -> u64 { self.enabled.heap_size_bytes() + self.strength.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/force_collision_radius.rs b/crates/store/re_types/src/blueprint/archetypes/force_collision_radius.rs index 9f4536a2b750..0b96b70eb130 100644 --- a/crates/store/re_types/src/blueprint/archetypes/force_collision_radius.rs +++ b/crates/store/re_types/src/blueprint/archetypes/force_collision_radius.rs @@ -287,7 +287,7 @@ impl ForceCollisionRadius { } } -impl ::re_types_core::SizeBytes for ForceCollisionRadius { +impl ::re_byte_size::SizeBytes for ForceCollisionRadius { #[inline] fn heap_size_bytes(&self) -> u64 { self.enabled.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/force_link.rs b/crates/store/re_types/src/blueprint/archetypes/force_link.rs index f294b0eb9818..48a74c597ec6 100644 --- a/crates/store/re_types/src/blueprint/archetypes/force_link.rs +++ b/crates/store/re_types/src/blueprint/archetypes/force_link.rs @@ -286,7 +286,7 @@ impl ForceLink { } } -impl ::re_types_core::SizeBytes for ForceLink { +impl ::re_byte_size::SizeBytes for ForceLink { #[inline] fn heap_size_bytes(&self) -> u64 { self.enabled.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/force_many_body.rs b/crates/store/re_types/src/blueprint/archetypes/force_many_body.rs index 026e249436d4..8226d87ffa69 100644 --- a/crates/store/re_types/src/blueprint/archetypes/force_many_body.rs +++ b/crates/store/re_types/src/blueprint/archetypes/force_many_body.rs @@ -240,7 +240,7 @@ impl ForceManyBody { } } -impl ::re_types_core::SizeBytes for ForceManyBody { +impl ::re_byte_size::SizeBytes for ForceManyBody { #[inline] fn heap_size_bytes(&self) -> u64 { self.enabled.heap_size_bytes() + self.strength.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/force_position.rs b/crates/store/re_types/src/blueprint/archetypes/force_position.rs index cc74aa2aabf4..e421bd606517 100644 --- a/crates/store/re_types/src/blueprint/archetypes/force_position.rs +++ b/crates/store/re_types/src/blueprint/archetypes/force_position.rs @@ -278,7 +278,7 @@ impl ForcePosition { } } -impl ::re_types_core::SizeBytes for ForcePosition { +impl ::re_byte_size::SizeBytes for ForcePosition { #[inline] fn heap_size_bytes(&self) -> u64 { self.enabled.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/line_grid3d.rs b/crates/store/re_types/src/blueprint/archetypes/line_grid3d.rs index 3442f7edc628..cc23e64147b5 100644 --- a/crates/store/re_types/src/blueprint/archetypes/line_grid3d.rs +++ b/crates/store/re_types/src/blueprint/archetypes/line_grid3d.rs @@ -387,7 +387,7 @@ impl LineGrid3D { } } -impl ::re_types_core::SizeBytes for LineGrid3D { +impl ::re_byte_size::SizeBytes for LineGrid3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.visible.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/map_background.rs b/crates/store/re_types/src/blueprint/archetypes/map_background.rs index 7efeb6d2a687..2630f1fe41ab 100644 --- a/crates/store/re_types/src/blueprint/archetypes/map_background.rs +++ b/crates/store/re_types/src/blueprint/archetypes/map_background.rs @@ -173,7 +173,7 @@ impl MapBackground { } } -impl ::re_types_core::SizeBytes for MapBackground { +impl ::re_byte_size::SizeBytes for MapBackground { #[inline] fn heap_size_bytes(&self) -> u64 { self.provider.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/map_zoom.rs b/crates/store/re_types/src/blueprint/archetypes/map_zoom.rs index d4f68720d285..166ff7396461 100644 --- a/crates/store/re_types/src/blueprint/archetypes/map_zoom.rs +++ b/crates/store/re_types/src/blueprint/archetypes/map_zoom.rs @@ -171,7 +171,7 @@ impl MapZoom { } } -impl ::re_types_core::SizeBytes for MapZoom { +impl ::re_byte_size::SizeBytes for MapZoom { #[inline] fn heap_size_bytes(&self) -> u64 { self.zoom.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/near_clip_plane.rs b/crates/store/re_types/src/blueprint/archetypes/near_clip_plane.rs index 9714d55ddff1..e96bce6791e9 100644 --- a/crates/store/re_types/src/blueprint/archetypes/near_clip_plane.rs +++ b/crates/store/re_types/src/blueprint/archetypes/near_clip_plane.rs @@ -173,7 +173,7 @@ impl NearClipPlane { } } -impl ::re_types_core::SizeBytes for NearClipPlane { +impl ::re_byte_size::SizeBytes for NearClipPlane { #[inline] fn heap_size_bytes(&self) -> u64 { self.near_clip_plane.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/panel_blueprint.rs b/crates/store/re_types/src/blueprint/archetypes/panel_blueprint.rs index 7f55137e124f..de6b73607062 100644 --- a/crates/store/re_types/src/blueprint/archetypes/panel_blueprint.rs +++ b/crates/store/re_types/src/blueprint/archetypes/panel_blueprint.rs @@ -178,7 +178,7 @@ impl PanelBlueprint { } } -impl ::re_types_core::SizeBytes for PanelBlueprint { +impl ::re_byte_size::SizeBytes for PanelBlueprint { #[inline] fn heap_size_bytes(&self) -> u64 { self.state.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/plot_legend.rs b/crates/store/re_types/src/blueprint/archetypes/plot_legend.rs index 7c371c5c9a44..680e02c21dbe 100644 --- a/crates/store/re_types/src/blueprint/archetypes/plot_legend.rs +++ b/crates/store/re_types/src/blueprint/archetypes/plot_legend.rs @@ -236,7 +236,7 @@ impl PlotLegend { } } -impl ::re_types_core::SizeBytes for PlotLegend { +impl ::re_byte_size::SizeBytes for PlotLegend { #[inline] fn heap_size_bytes(&self) -> u64 { self.corner.heap_size_bytes() + self.visible.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/scalar_axis.rs b/crates/store/re_types/src/blueprint/archetypes/scalar_axis.rs index a6a75ebc6def..d480f60a0fc6 100644 --- a/crates/store/re_types/src/blueprint/archetypes/scalar_axis.rs +++ b/crates/store/re_types/src/blueprint/archetypes/scalar_axis.rs @@ -229,7 +229,7 @@ impl ScalarAxis { } } -impl ::re_types_core::SizeBytes for ScalarAxis { +impl ::re_byte_size::SizeBytes for ScalarAxis { #[inline] fn heap_size_bytes(&self) -> u64 { self.range.heap_size_bytes() + self.zoom_lock.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/tensor_scalar_mapping.rs b/crates/store/re_types/src/blueprint/archetypes/tensor_scalar_mapping.rs index 0756e3347a66..3a7629ec4f8e 100644 --- a/crates/store/re_types/src/blueprint/archetypes/tensor_scalar_mapping.rs +++ b/crates/store/re_types/src/blueprint/archetypes/tensor_scalar_mapping.rs @@ -287,7 +287,7 @@ impl TensorScalarMapping { } } -impl ::re_types_core::SizeBytes for TensorScalarMapping { +impl ::re_byte_size::SizeBytes for TensorScalarMapping { #[inline] fn heap_size_bytes(&self) -> u64 { self.mag_filter.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/tensor_slice_selection.rs b/crates/store/re_types/src/blueprint/archetypes/tensor_slice_selection.rs index 422cd47a38d7..3caf98b15176 100644 --- a/crates/store/re_types/src/blueprint/archetypes/tensor_slice_selection.rs +++ b/crates/store/re_types/src/blueprint/archetypes/tensor_slice_selection.rs @@ -356,7 +356,7 @@ impl TensorSliceSelection { } } -impl ::re_types_core::SizeBytes for TensorSliceSelection { +impl ::re_byte_size::SizeBytes for TensorSliceSelection { #[inline] fn heap_size_bytes(&self) -> u64 { self.width.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/tensor_view_fit.rs b/crates/store/re_types/src/blueprint/archetypes/tensor_view_fit.rs index 8e6bbfd0aa10..88a0f5dd7cc9 100644 --- a/crates/store/re_types/src/blueprint/archetypes/tensor_view_fit.rs +++ b/crates/store/re_types/src/blueprint/archetypes/tensor_view_fit.rs @@ -178,7 +178,7 @@ impl TensorViewFit { } } -impl ::re_types_core::SizeBytes for TensorViewFit { +impl ::re_byte_size::SizeBytes for TensorViewFit { #[inline] fn heap_size_bytes(&self) -> u64 { self.scaling.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/view_blueprint.rs b/crates/store/re_types/src/blueprint/archetypes/view_blueprint.rs index 2cc4714acc07..9fe71e9de559 100644 --- a/crates/store/re_types/src/blueprint/archetypes/view_blueprint.rs +++ b/crates/store/re_types/src/blueprint/archetypes/view_blueprint.rs @@ -329,7 +329,7 @@ impl ViewBlueprint { } } -impl ::re_types_core::SizeBytes for ViewBlueprint { +impl ::re_byte_size::SizeBytes for ViewBlueprint { #[inline] fn heap_size_bytes(&self) -> u64 { self.class_identifier.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/view_contents.rs b/crates/store/re_types/src/blueprint/archetypes/view_contents.rs index a748140632bd..3d7fc75ac6ba 100644 --- a/crates/store/re_types/src/blueprint/archetypes/view_contents.rs +++ b/crates/store/re_types/src/blueprint/archetypes/view_contents.rs @@ -211,7 +211,7 @@ impl ViewContents { } } -impl ::re_types_core::SizeBytes for ViewContents { +impl ::re_byte_size::SizeBytes for ViewContents { #[inline] fn heap_size_bytes(&self) -> u64 { self.query.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/viewport_blueprint.rs b/crates/store/re_types/src/blueprint/archetypes/viewport_blueprint.rs index 5c75fa92e887..b75f3a80a25a 100644 --- a/crates/store/re_types/src/blueprint/archetypes/viewport_blueprint.rs +++ b/crates/store/re_types/src/blueprint/archetypes/viewport_blueprint.rs @@ -412,7 +412,7 @@ impl ViewportBlueprint { } } -impl ::re_types_core::SizeBytes for ViewportBlueprint { +impl ::re_byte_size::SizeBytes for ViewportBlueprint { #[inline] fn heap_size_bytes(&self) -> u64 { self.root_container.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/visible_time_ranges.rs b/crates/store/re_types/src/blueprint/archetypes/visible_time_ranges.rs index 8056a916b681..4c7ae351c3f3 100644 --- a/crates/store/re_types/src/blueprint/archetypes/visible_time_ranges.rs +++ b/crates/store/re_types/src/blueprint/archetypes/visible_time_ranges.rs @@ -182,7 +182,7 @@ impl VisibleTimeRanges { } } -impl ::re_types_core::SizeBytes for VisibleTimeRanges { +impl ::re_byte_size::SizeBytes for VisibleTimeRanges { #[inline] fn heap_size_bytes(&self) -> u64 { self.ranges.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/archetypes/visual_bounds2d.rs b/crates/store/re_types/src/blueprint/archetypes/visual_bounds2d.rs index e409e5dbd94a..44b203026688 100644 --- a/crates/store/re_types/src/blueprint/archetypes/visual_bounds2d.rs +++ b/crates/store/re_types/src/blueprint/archetypes/visual_bounds2d.rs @@ -179,7 +179,7 @@ impl VisualBounds2D { } } -impl ::re_types_core::SizeBytes for VisualBounds2D { +impl ::re_byte_size::SizeBytes for VisualBounds2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.range.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/active_tab.rs b/crates/store/re_types/src/blueprint/components/active_tab.rs index 36b7359658fc..f9dca46d8890 100644 --- a/crates/store/re_types/src/blueprint/components/active_tab.rs +++ b/crates/store/re_types/src/blueprint/components/active_tab.rs @@ -96,7 +96,7 @@ impl std::ops::DerefMut for ActiveTab { } } -impl ::re_types_core::SizeBytes for ActiveTab { +impl ::re_byte_size::SizeBytes for ActiveTab { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/apply_latest_at.rs b/crates/store/re_types/src/blueprint/components/apply_latest_at.rs index faf8dc094e44..ae3aa97c20dd 100644 --- a/crates/store/re_types/src/blueprint/components/apply_latest_at.rs +++ b/crates/store/re_types/src/blueprint/components/apply_latest_at.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for ApplyLatestAt { } } -impl ::re_types_core::SizeBytes for ApplyLatestAt { +impl ::re_byte_size::SizeBytes for ApplyLatestAt { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/auto_layout.rs b/crates/store/re_types/src/blueprint/components/auto_layout.rs index d4087718ebd8..9a4c2c7ee1fd 100644 --- a/crates/store/re_types/src/blueprint/components/auto_layout.rs +++ b/crates/store/re_types/src/blueprint/components/auto_layout.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for AutoLayout { } } -impl ::re_types_core::SizeBytes for AutoLayout { +impl ::re_byte_size::SizeBytes for AutoLayout { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/auto_views.rs b/crates/store/re_types/src/blueprint/components/auto_views.rs index a25155016fc0..cdad353f80ed 100644 --- a/crates/store/re_types/src/blueprint/components/auto_views.rs +++ b/crates/store/re_types/src/blueprint/components/auto_views.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for AutoViews { } } -impl ::re_types_core::SizeBytes for AutoViews { +impl ::re_byte_size::SizeBytes for AutoViews { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/background_kind.rs b/crates/store/re_types/src/blueprint/components/background_kind.rs index 64bad27240f1..8647bc5025f9 100644 --- a/crates/store/re_types/src/blueprint/components/background_kind.rs +++ b/crates/store/re_types/src/blueprint/components/background_kind.rs @@ -157,7 +157,7 @@ impl ::re_types_core::reflection::Enum for BackgroundKind { } } -impl ::re_types_core::SizeBytes for BackgroundKind { +impl ::re_byte_size::SizeBytes for BackgroundKind { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/column_share.rs b/crates/store/re_types/src/blueprint/components/column_share.rs index 635ede9eaadd..433f48f191f6 100644 --- a/crates/store/re_types/src/blueprint/components/column_share.rs +++ b/crates/store/re_types/src/blueprint/components/column_share.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for ColumnShare { } } -impl ::re_types_core::SizeBytes for ColumnShare { +impl ::re_byte_size::SizeBytes for ColumnShare { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/component_column_selector.rs b/crates/store/re_types/src/blueprint/components/component_column_selector.rs index f76bd4be51a5..7e60aeddd873 100644 --- a/crates/store/re_types/src/blueprint/components/component_column_selector.rs +++ b/crates/store/re_types/src/blueprint/components/component_column_selector.rs @@ -98,7 +98,7 @@ impl std::ops::DerefMut for ComponentColumnSelector { } } -impl ::re_types_core::SizeBytes for ComponentColumnSelector { +impl ::re_byte_size::SizeBytes for ComponentColumnSelector { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/container_kind.rs b/crates/store/re_types/src/blueprint/components/container_kind.rs index 4c3c81c027ae..707e2e063821 100644 --- a/crates/store/re_types/src/blueprint/components/container_kind.rs +++ b/crates/store/re_types/src/blueprint/components/container_kind.rs @@ -155,7 +155,7 @@ impl ::re_types_core::reflection::Enum for ContainerKind { } } -impl ::re_types_core::SizeBytes for ContainerKind { +impl ::re_byte_size::SizeBytes for ContainerKind { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/corner2d.rs b/crates/store/re_types/src/blueprint/components/corner2d.rs index 2df6b4e36c59..d559cf480356 100644 --- a/crates/store/re_types/src/blueprint/components/corner2d.rs +++ b/crates/store/re_types/src/blueprint/components/corner2d.rs @@ -160,7 +160,7 @@ impl ::re_types_core::reflection::Enum for Corner2D { } } -impl ::re_types_core::SizeBytes for Corner2D { +impl ::re_byte_size::SizeBytes for Corner2D { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/enabled.rs b/crates/store/re_types/src/blueprint/components/enabled.rs index dc258abb03d2..2f7772fa7908 100644 --- a/crates/store/re_types/src/blueprint/components/enabled.rs +++ b/crates/store/re_types/src/blueprint/components/enabled.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for Enabled { } } -impl ::re_types_core::SizeBytes for Enabled { +impl ::re_byte_size::SizeBytes for Enabled { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/filter_by_range.rs b/crates/store/re_types/src/blueprint/components/filter_by_range.rs index 5b629bb95e69..a4c1977b1b30 100644 --- a/crates/store/re_types/src/blueprint/components/filter_by_range.rs +++ b/crates/store/re_types/src/blueprint/components/filter_by_range.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for FilterByRange { } } -impl ::re_types_core::SizeBytes for FilterByRange { +impl ::re_byte_size::SizeBytes for FilterByRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/filter_is_not_null.rs b/crates/store/re_types/src/blueprint/components/filter_is_not_null.rs index 5be06c34de17..bde7ecb1291b 100644 --- a/crates/store/re_types/src/blueprint/components/filter_is_not_null.rs +++ b/crates/store/re_types/src/blueprint/components/filter_is_not_null.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for FilterIsNotNull { } } -impl ::re_types_core::SizeBytes for FilterIsNotNull { +impl ::re_byte_size::SizeBytes for FilterIsNotNull { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/force_distance.rs b/crates/store/re_types/src/blueprint/components/force_distance.rs index 8a70ffc068f7..cfb75888a9ef 100644 --- a/crates/store/re_types/src/blueprint/components/force_distance.rs +++ b/crates/store/re_types/src/blueprint/components/force_distance.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for ForceDistance { } } -impl ::re_types_core::SizeBytes for ForceDistance { +impl ::re_byte_size::SizeBytes for ForceDistance { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/force_iterations.rs b/crates/store/re_types/src/blueprint/components/force_iterations.rs index d91a043a615f..8a375a9165c9 100644 --- a/crates/store/re_types/src/blueprint/components/force_iterations.rs +++ b/crates/store/re_types/src/blueprint/components/force_iterations.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for ForceIterations { } } -impl ::re_types_core::SizeBytes for ForceIterations { +impl ::re_byte_size::SizeBytes for ForceIterations { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/force_strength.rs b/crates/store/re_types/src/blueprint/components/force_strength.rs index d1efe60bbb4f..c11e47292980 100644 --- a/crates/store/re_types/src/blueprint/components/force_strength.rs +++ b/crates/store/re_types/src/blueprint/components/force_strength.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for ForceStrength { } } -impl ::re_types_core::SizeBytes for ForceStrength { +impl ::re_byte_size::SizeBytes for ForceStrength { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/grid_columns.rs b/crates/store/re_types/src/blueprint/components/grid_columns.rs index 6ed979d90197..b37e4332386c 100644 --- a/crates/store/re_types/src/blueprint/components/grid_columns.rs +++ b/crates/store/re_types/src/blueprint/components/grid_columns.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for GridColumns { } } -impl ::re_types_core::SizeBytes for GridColumns { +impl ::re_byte_size::SizeBytes for GridColumns { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/grid_spacing.rs b/crates/store/re_types/src/blueprint/components/grid_spacing.rs index 4015a22ff884..51bfe06e86b9 100644 --- a/crates/store/re_types/src/blueprint/components/grid_spacing.rs +++ b/crates/store/re_types/src/blueprint/components/grid_spacing.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for GridSpacing { } } -impl ::re_types_core::SizeBytes for GridSpacing { +impl ::re_byte_size::SizeBytes for GridSpacing { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/included_content.rs b/crates/store/re_types/src/blueprint/components/included_content.rs index 1cadd10724f0..4e0fa4d15323 100644 --- a/crates/store/re_types/src/blueprint/components/included_content.rs +++ b/crates/store/re_types/src/blueprint/components/included_content.rs @@ -97,7 +97,7 @@ impl std::ops::DerefMut for IncludedContent { } } -impl ::re_types_core::SizeBytes for IncludedContent { +impl ::re_byte_size::SizeBytes for IncludedContent { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/interactive.rs b/crates/store/re_types/src/blueprint/components/interactive.rs index 05e3f7ace7f4..2cca04de6896 100644 --- a/crates/store/re_types/src/blueprint/components/interactive.rs +++ b/crates/store/re_types/src/blueprint/components/interactive.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for Interactive { } } -impl ::re_types_core::SizeBytes for Interactive { +impl ::re_byte_size::SizeBytes for Interactive { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/lock_range_during_zoom.rs b/crates/store/re_types/src/blueprint/components/lock_range_during_zoom.rs index db8c730d2c55..4625f150d0a7 100644 --- a/crates/store/re_types/src/blueprint/components/lock_range_during_zoom.rs +++ b/crates/store/re_types/src/blueprint/components/lock_range_during_zoom.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for LockRangeDuringZoom { } } -impl ::re_types_core::SizeBytes for LockRangeDuringZoom { +impl ::re_byte_size::SizeBytes for LockRangeDuringZoom { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/map_provider.rs b/crates/store/re_types/src/blueprint/components/map_provider.rs index 7a8e4216ed51..211036fb4bb5 100644 --- a/crates/store/re_types/src/blueprint/components/map_provider.rs +++ b/crates/store/re_types/src/blueprint/components/map_provider.rs @@ -160,7 +160,7 @@ impl ::re_types_core::reflection::Enum for MapProvider { } } -impl ::re_types_core::SizeBytes for MapProvider { +impl ::re_byte_size::SizeBytes for MapProvider { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/near_clip_plane.rs b/crates/store/re_types/src/blueprint/components/near_clip_plane.rs index b9caf19b944d..02b2ae01e317 100644 --- a/crates/store/re_types/src/blueprint/components/near_clip_plane.rs +++ b/crates/store/re_types/src/blueprint/components/near_clip_plane.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for NearClipPlane { } } -impl ::re_types_core::SizeBytes for NearClipPlane { +impl ::re_byte_size::SizeBytes for NearClipPlane { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/panel_state.rs b/crates/store/re_types/src/blueprint/components/panel_state.rs index 5ed60f06fba7..bccf62cf1aaa 100644 --- a/crates/store/re_types/src/blueprint/components/panel_state.rs +++ b/crates/store/re_types/src/blueprint/components/panel_state.rs @@ -149,7 +149,7 @@ impl ::re_types_core::reflection::Enum for PanelState { } } -impl ::re_types_core::SizeBytes for PanelState { +impl ::re_byte_size::SizeBytes for PanelState { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/query_expression.rs b/crates/store/re_types/src/blueprint/components/query_expression.rs index d3684644b5d4..4c0377d5fff9 100644 --- a/crates/store/re_types/src/blueprint/components/query_expression.rs +++ b/crates/store/re_types/src/blueprint/components/query_expression.rs @@ -101,7 +101,7 @@ impl std::ops::DerefMut for QueryExpression { } } -impl ::re_types_core::SizeBytes for QueryExpression { +impl ::re_byte_size::SizeBytes for QueryExpression { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/root_container.rs b/crates/store/re_types/src/blueprint/components/root_container.rs index be4161f2de22..9b96744c0c31 100644 --- a/crates/store/re_types/src/blueprint/components/root_container.rs +++ b/crates/store/re_types/src/blueprint/components/root_container.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for RootContainer { } } -impl ::re_types_core::SizeBytes for RootContainer { +impl ::re_byte_size::SizeBytes for RootContainer { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/row_share.rs b/crates/store/re_types/src/blueprint/components/row_share.rs index 290ee9d7ce58..3e0530bdaae5 100644 --- a/crates/store/re_types/src/blueprint/components/row_share.rs +++ b/crates/store/re_types/src/blueprint/components/row_share.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for RowShare { } } -impl ::re_types_core::SizeBytes for RowShare { +impl ::re_byte_size::SizeBytes for RowShare { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/selected_columns.rs b/crates/store/re_types/src/blueprint/components/selected_columns.rs index 31d6e0754b29..9e86aeec60f8 100644 --- a/crates/store/re_types/src/blueprint/components/selected_columns.rs +++ b/crates/store/re_types/src/blueprint/components/selected_columns.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for SelectedColumns { } } -impl ::re_types_core::SizeBytes for SelectedColumns { +impl ::re_byte_size::SizeBytes for SelectedColumns { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/tensor_dimension_index_slider.rs b/crates/store/re_types/src/blueprint/components/tensor_dimension_index_slider.rs index 914bc4e2eca4..f1288446042f 100644 --- a/crates/store/re_types/src/blueprint/components/tensor_dimension_index_slider.rs +++ b/crates/store/re_types/src/blueprint/components/tensor_dimension_index_slider.rs @@ -98,7 +98,7 @@ impl std::ops::DerefMut for TensorDimensionIndexSlider { } } -impl ::re_types_core::SizeBytes for TensorDimensionIndexSlider { +impl ::re_byte_size::SizeBytes for TensorDimensionIndexSlider { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/timeline_name.rs b/crates/store/re_types/src/blueprint/components/timeline_name.rs index efc7f680c876..d0b8dae59d82 100644 --- a/crates/store/re_types/src/blueprint/components/timeline_name.rs +++ b/crates/store/re_types/src/blueprint/components/timeline_name.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for TimelineName { } } -impl ::re_types_core::SizeBytes for TimelineName { +impl ::re_byte_size::SizeBytes for TimelineName { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/view_class.rs b/crates/store/re_types/src/blueprint/components/view_class.rs index 4496488e546b..9755d95627c1 100644 --- a/crates/store/re_types/src/blueprint/components/view_class.rs +++ b/crates/store/re_types/src/blueprint/components/view_class.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for ViewClass { } } -impl ::re_types_core::SizeBytes for ViewClass { +impl ::re_byte_size::SizeBytes for ViewClass { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/view_fit.rs b/crates/store/re_types/src/blueprint/components/view_fit.rs index 22d7a8288b1f..fe86ad463f5f 100644 --- a/crates/store/re_types/src/blueprint/components/view_fit.rs +++ b/crates/store/re_types/src/blueprint/components/view_fit.rs @@ -155,7 +155,7 @@ impl ::re_types_core::reflection::Enum for ViewFit { } } -impl ::re_types_core::SizeBytes for ViewFit { +impl ::re_byte_size::SizeBytes for ViewFit { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/components/view_maximized.rs b/crates/store/re_types/src/blueprint/components/view_maximized.rs index 013b81cebc55..e99e14e801a2 100644 --- a/crates/store/re_types/src/blueprint/components/view_maximized.rs +++ b/crates/store/re_types/src/blueprint/components/view_maximized.rs @@ -99,7 +99,7 @@ impl std::ops::DerefMut for ViewMaximized { } } -impl ::re_types_core::SizeBytes for ViewMaximized { +impl ::re_byte_size::SizeBytes for ViewMaximized { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/view_origin.rs b/crates/store/re_types/src/blueprint/components/view_origin.rs index 09d16f92615d..ce9d1e0b7862 100644 --- a/crates/store/re_types/src/blueprint/components/view_origin.rs +++ b/crates/store/re_types/src/blueprint/components/view_origin.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for ViewOrigin { } } -impl ::re_types_core::SizeBytes for ViewOrigin { +impl ::re_byte_size::SizeBytes for ViewOrigin { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/viewer_recommendation_hash.rs b/crates/store/re_types/src/blueprint/components/viewer_recommendation_hash.rs index be679b705c38..ce2dda50dfde 100644 --- a/crates/store/re_types/src/blueprint/components/viewer_recommendation_hash.rs +++ b/crates/store/re_types/src/blueprint/components/viewer_recommendation_hash.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for ViewerRecommendationHash { } } -impl ::re_types_core::SizeBytes for ViewerRecommendationHash { +impl ::re_byte_size::SizeBytes for ViewerRecommendationHash { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/visible.rs b/crates/store/re_types/src/blueprint/components/visible.rs index c4322a8dbd58..c7e8dfd0db70 100644 --- a/crates/store/re_types/src/blueprint/components/visible.rs +++ b/crates/store/re_types/src/blueprint/components/visible.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for Visible { } } -impl ::re_types_core::SizeBytes for Visible { +impl ::re_byte_size::SizeBytes for Visible { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/visible_time_range.rs b/crates/store/re_types/src/blueprint/components/visible_time_range.rs index 4f9685db7677..fa41651de7db 100644 --- a/crates/store/re_types/src/blueprint/components/visible_time_range.rs +++ b/crates/store/re_types/src/blueprint/components/visible_time_range.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for VisibleTimeRange { } } -impl ::re_types_core::SizeBytes for VisibleTimeRange { +impl ::re_byte_size::SizeBytes for VisibleTimeRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/visual_bounds2d.rs b/crates/store/re_types/src/blueprint/components/visual_bounds2d.rs index fefb606c8f46..45cb993fc93f 100644 --- a/crates/store/re_types/src/blueprint/components/visual_bounds2d.rs +++ b/crates/store/re_types/src/blueprint/components/visual_bounds2d.rs @@ -95,7 +95,7 @@ impl std::ops::DerefMut for VisualBounds2D { } } -impl ::re_types_core::SizeBytes for VisualBounds2D { +impl ::re_byte_size::SizeBytes for VisualBounds2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/visualizer_overrides.rs b/crates/store/re_types/src/blueprint/components/visualizer_overrides.rs index 99b03d0960a2..bc97f1ad55ee 100644 --- a/crates/store/re_types/src/blueprint/components/visualizer_overrides.rs +++ b/crates/store/re_types/src/blueprint/components/visualizer_overrides.rs @@ -104,7 +104,7 @@ impl std::ops::DerefMut for VisualizerOverrides { } } -impl ::re_types_core::SizeBytes for VisualizerOverrides { +impl ::re_byte_size::SizeBytes for VisualizerOverrides { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/components/zoom_level.rs b/crates/store/re_types/src/blueprint/components/zoom_level.rs index f25a6decb5b2..789f7e90de43 100644 --- a/crates/store/re_types/src/blueprint/components/zoom_level.rs +++ b/crates/store/re_types/src/blueprint/components/zoom_level.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for ZoomLevel { } } -impl ::re_types_core::SizeBytes for ZoomLevel { +impl ::re_byte_size::SizeBytes for ZoomLevel { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/component_column_selector.rs b/crates/store/re_types/src/blueprint/datatypes/component_column_selector.rs index dd0694d2ab66..8de128154d3a 100644 --- a/crates/store/re_types/src/blueprint/datatypes/component_column_selector.rs +++ b/crates/store/re_types/src/blueprint/datatypes/component_column_selector.rs @@ -335,7 +335,7 @@ impl ::re_types_core::Loggable for ComponentColumnSelector { } } -impl ::re_types_core::SizeBytes for ComponentColumnSelector { +impl ::re_byte_size::SizeBytes for ComponentColumnSelector { #[inline] fn heap_size_bytes(&self) -> u64 { self.entity_path.heap_size_bytes() + self.component.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/filter_by_range.rs b/crates/store/re_types/src/blueprint/datatypes/filter_by_range.rs index c74756eaa46e..0b6ab64c32cf 100644 --- a/crates/store/re_types/src/blueprint/datatypes/filter_by_range.rs +++ b/crates/store/re_types/src/blueprint/datatypes/filter_by_range.rs @@ -225,7 +225,7 @@ impl ::re_types_core::Loggable for FilterByRange { } } -impl ::re_types_core::SizeBytes for FilterByRange { +impl ::re_byte_size::SizeBytes for FilterByRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.start.heap_size_bytes() + self.end.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/filter_is_not_null.rs b/crates/store/re_types/src/blueprint/datatypes/filter_is_not_null.rs index e747cf1e93f3..903ab5ad0b05 100644 --- a/crates/store/re_types/src/blueprint/datatypes/filter_is_not_null.rs +++ b/crates/store/re_types/src/blueprint/datatypes/filter_is_not_null.rs @@ -215,7 +215,7 @@ impl ::re_types_core::Loggable for FilterIsNotNull { } } -impl ::re_types_core::SizeBytes for FilterIsNotNull { +impl ::re_byte_size::SizeBytes for FilterIsNotNull { #[inline] fn heap_size_bytes(&self) -> u64 { self.active.heap_size_bytes() + self.column.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/selected_columns.rs b/crates/store/re_types/src/blueprint/datatypes/selected_columns.rs index 4bb0cec1fea9..8b9c8582fc8c 100644 --- a/crates/store/re_types/src/blueprint/datatypes/selected_columns.rs +++ b/crates/store/re_types/src/blueprint/datatypes/selected_columns.rs @@ -453,7 +453,7 @@ impl ::re_types_core::Loggable for SelectedColumns { } } -impl ::re_types_core::SizeBytes for SelectedColumns { +impl ::re_byte_size::SizeBytes for SelectedColumns { #[inline] fn heap_size_bytes(&self) -> u64 { self.time_columns.heap_size_bytes() + self.component_columns.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/tensor_dimension_index_slider.rs b/crates/store/re_types/src/blueprint/datatypes/tensor_dimension_index_slider.rs index fa525e58dee9..dd1a0e7deb4d 100644 --- a/crates/store/re_types/src/blueprint/datatypes/tensor_dimension_index_slider.rs +++ b/crates/store/re_types/src/blueprint/datatypes/tensor_dimension_index_slider.rs @@ -181,7 +181,7 @@ impl From for u32 { } } -impl ::re_types_core::SizeBytes for TensorDimensionIndexSlider { +impl ::re_byte_size::SizeBytes for TensorDimensionIndexSlider { #[inline] fn heap_size_bytes(&self) -> u64 { self.dimension.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/datatypes/utf8list.rs b/crates/store/re_types/src/blueprint/datatypes/utf8list.rs index 1e1d612b53c2..4415317faa84 100644 --- a/crates/store/re_types/src/blueprint/datatypes/utf8list.rs +++ b/crates/store/re_types/src/blueprint/datatypes/utf8list.rs @@ -216,7 +216,7 @@ impl From for Vec<::re_types_core::ArrowString> { } } -impl ::re_types_core::SizeBytes for Utf8List { +impl ::re_byte_size::SizeBytes for Utf8List { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/bar_chart_view.rs b/crates/store/re_types/src/blueprint/views/bar_chart_view.rs index 6bee621d477e..312358ad3e76 100644 --- a/crates/store/re_types/src/blueprint/views/bar_chart_view.rs +++ b/crates/store/re_types/src/blueprint/views/bar_chart_view.rs @@ -63,7 +63,7 @@ impl std::ops::DerefMut for BarChartView { } } -impl ::re_types_core::SizeBytes for BarChartView { +impl ::re_byte_size::SizeBytes for BarChartView { #[inline] fn heap_size_bytes(&self) -> u64 { self.plot_legend.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/dataframe_view.rs b/crates/store/re_types/src/blueprint/views/dataframe_view.rs index 0c2cb2b288ba..0ea411a270fa 100644 --- a/crates/store/re_types/src/blueprint/views/dataframe_view.rs +++ b/crates/store/re_types/src/blueprint/views/dataframe_view.rs @@ -63,7 +63,7 @@ impl std::ops::DerefMut for DataframeView { } } -impl ::re_types_core::SizeBytes for DataframeView { +impl ::re_byte_size::SizeBytes for DataframeView { #[inline] fn heap_size_bytes(&self) -> u64 { self.query.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/graph_view.rs b/crates/store/re_types/src/blueprint/views/graph_view.rs index 3ff1d79abf64..84a351f5b8fd 100644 --- a/crates/store/re_types/src/blueprint/views/graph_view.rs +++ b/crates/store/re_types/src/blueprint/views/graph_view.rs @@ -49,7 +49,7 @@ impl ::re_types_core::View for GraphView { } } -impl ::re_types_core::SizeBytes for GraphView { +impl ::re_byte_size::SizeBytes for GraphView { #[inline] fn heap_size_bytes(&self) -> u64 { self.visual_bounds.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/map_view.rs b/crates/store/re_types/src/blueprint/views/map_view.rs index 749234094780..26f7a5a0cba1 100644 --- a/crates/store/re_types/src/blueprint/views/map_view.rs +++ b/crates/store/re_types/src/blueprint/views/map_view.rs @@ -35,7 +35,7 @@ impl ::re_types_core::View for MapView { } } -impl ::re_types_core::SizeBytes for MapView { +impl ::re_byte_size::SizeBytes for MapView { #[inline] fn heap_size_bytes(&self) -> u64 { self.zoom.heap_size_bytes() + self.background.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/spatial2d_view.rs b/crates/store/re_types/src/blueprint/views/spatial2d_view.rs index 68dce6e28e47..bf560a2322df 100644 --- a/crates/store/re_types/src/blueprint/views/spatial2d_view.rs +++ b/crates/store/re_types/src/blueprint/views/spatial2d_view.rs @@ -44,7 +44,7 @@ impl ::re_types_core::View for Spatial2DView { } } -impl ::re_types_core::SizeBytes for Spatial2DView { +impl ::re_byte_size::SizeBytes for Spatial2DView { #[inline] fn heap_size_bytes(&self) -> u64 { self.background.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/spatial3d_view.rs b/crates/store/re_types/src/blueprint/views/spatial3d_view.rs index 8f562935cf37..cd0edb0bd8e1 100644 --- a/crates/store/re_types/src/blueprint/views/spatial3d_view.rs +++ b/crates/store/re_types/src/blueprint/views/spatial3d_view.rs @@ -41,7 +41,7 @@ impl ::re_types_core::View for Spatial3DView { } } -impl ::re_types_core::SizeBytes for Spatial3DView { +impl ::re_byte_size::SizeBytes for Spatial3DView { #[inline] fn heap_size_bytes(&self) -> u64 { self.background.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/tensor_view.rs b/crates/store/re_types/src/blueprint/views/tensor_view.rs index efdf00a55232..7b678bd75989 100644 --- a/crates/store/re_types/src/blueprint/views/tensor_view.rs +++ b/crates/store/re_types/src/blueprint/views/tensor_view.rs @@ -38,7 +38,7 @@ impl ::re_types_core::View for TensorView { } } -impl ::re_types_core::SizeBytes for TensorView { +impl ::re_byte_size::SizeBytes for TensorView { #[inline] fn heap_size_bytes(&self) -> u64 { self.slice_selection.heap_size_bytes() diff --git a/crates/store/re_types/src/blueprint/views/text_document_view.rs b/crates/store/re_types/src/blueprint/views/text_document_view.rs index ef82928a58c9..8b15a4287bb0 100644 --- a/crates/store/re_types/src/blueprint/views/text_document_view.rs +++ b/crates/store/re_types/src/blueprint/views/text_document_view.rs @@ -29,7 +29,7 @@ impl ::re_types_core::View for TextDocumentView { } } -impl ::re_types_core::SizeBytes for TextDocumentView { +impl ::re_byte_size::SizeBytes for TextDocumentView { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/views/text_log_view.rs b/crates/store/re_types/src/blueprint/views/text_log_view.rs index 044b5f916b52..8aca0cd7a5af 100644 --- a/crates/store/re_types/src/blueprint/views/text_log_view.rs +++ b/crates/store/re_types/src/blueprint/views/text_log_view.rs @@ -29,7 +29,7 @@ impl ::re_types_core::View for TextLogView { } } -impl ::re_types_core::SizeBytes for TextLogView { +impl ::re_byte_size::SizeBytes for TextLogView { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/blueprint/views/time_series_view.rs b/crates/store/re_types/src/blueprint/views/time_series_view.rs index fc81295ba79e..425be3792500 100644 --- a/crates/store/re_types/src/blueprint/views/time_series_view.rs +++ b/crates/store/re_types/src/blueprint/views/time_series_view.rs @@ -41,7 +41,7 @@ impl ::re_types_core::View for TimeSeriesView { } } -impl ::re_types_core::SizeBytes for TimeSeriesView { +impl ::re_byte_size::SizeBytes for TimeSeriesView { #[inline] fn heap_size_bytes(&self) -> u64 { self.axis_y.heap_size_bytes() diff --git a/crates/store/re_types/src/components/aggregation_policy.rs b/crates/store/re_types/src/components/aggregation_policy.rs index df61f0eea61c..f5f9027fc021 100644 --- a/crates/store/re_types/src/components/aggregation_policy.rs +++ b/crates/store/re_types/src/components/aggregation_policy.rs @@ -184,7 +184,7 @@ impl ::re_types_core::reflection::Enum for AggregationPolicy { } } -impl ::re_types_core::SizeBytes for AggregationPolicy { +impl ::re_byte_size::SizeBytes for AggregationPolicy { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/albedo_factor.rs b/crates/store/re_types/src/components/albedo_factor.rs index 916352c94bd3..12566a78ff1c 100644 --- a/crates/store/re_types/src/components/albedo_factor.rs +++ b/crates/store/re_types/src/components/albedo_factor.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for AlbedoFactor { } } -impl ::re_types_core::SizeBytes for AlbedoFactor { +impl ::re_byte_size::SizeBytes for AlbedoFactor { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/annotation_context.rs b/crates/store/re_types/src/components/annotation_context.rs index c24f64f2d2fd..80db053df701 100644 --- a/crates/store/re_types/src/components/annotation_context.rs +++ b/crates/store/re_types/src/components/annotation_context.rs @@ -179,7 +179,7 @@ impl, T: IntoIterator u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/axis_length.rs b/crates/store/re_types/src/components/axis_length.rs index c9c9b7780f14..5f806721ab4d 100644 --- a/crates/store/re_types/src/components/axis_length.rs +++ b/crates/store/re_types/src/components/axis_length.rs @@ -101,7 +101,7 @@ impl std::ops::DerefMut for AxisLength { } } -impl ::re_types_core::SizeBytes for AxisLength { +impl ::re_byte_size::SizeBytes for AxisLength { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/blob.rs b/crates/store/re_types/src/components/blob.rs index d504c0b61537..7cd2dea43574 100644 --- a/crates/store/re_types/src/components/blob.rs +++ b/crates/store/re_types/src/components/blob.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for Blob { } } -impl ::re_types_core::SizeBytes for Blob { +impl ::re_byte_size::SizeBytes for Blob { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/class_id.rs b/crates/store/re_types/src/components/class_id.rs index 3d566e2b07d7..58d82df85d7d 100644 --- a/crates/store/re_types/src/components/class_id.rs +++ b/crates/store/re_types/src/components/class_id.rs @@ -105,7 +105,7 @@ impl std::ops::DerefMut for ClassId { } } -impl ::re_types_core::SizeBytes for ClassId { +impl ::re_byte_size::SizeBytes for ClassId { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/color.rs b/crates/store/re_types/src/components/color.rs index a7a7c34e5ed9..c1fb73f74545 100644 --- a/crates/store/re_types/src/components/color.rs +++ b/crates/store/re_types/src/components/color.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for Color { } } -impl ::re_types_core::SizeBytes for Color { +impl ::re_byte_size::SizeBytes for Color { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/colormap.rs b/crates/store/re_types/src/components/colormap.rs index fca2eccdf2d5..06be429c0f40 100644 --- a/crates/store/re_types/src/components/colormap.rs +++ b/crates/store/re_types/src/components/colormap.rs @@ -222,7 +222,7 @@ impl ::re_types_core::reflection::Enum for Colormap { } } -impl ::re_types_core::SizeBytes for Colormap { +impl ::re_byte_size::SizeBytes for Colormap { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/depth_meter.rs b/crates/store/re_types/src/components/depth_meter.rs index 45706c7b4932..7a00e812f60a 100644 --- a/crates/store/re_types/src/components/depth_meter.rs +++ b/crates/store/re_types/src/components/depth_meter.rs @@ -107,7 +107,7 @@ impl std::ops::DerefMut for DepthMeter { } } -impl ::re_types_core::SizeBytes for DepthMeter { +impl ::re_byte_size::SizeBytes for DepthMeter { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/disconnected_space.rs b/crates/store/re_types/src/components/disconnected_space.rs index cec09ea9d318..3a688c9c5a67 100644 --- a/crates/store/re_types/src/components/disconnected_space.rs +++ b/crates/store/re_types/src/components/disconnected_space.rs @@ -105,7 +105,7 @@ impl std::ops::DerefMut for DisconnectedSpace { } } -impl ::re_types_core::SizeBytes for DisconnectedSpace { +impl ::re_byte_size::SizeBytes for DisconnectedSpace { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/draw_order.rs b/crates/store/re_types/src/components/draw_order.rs index 3e745d780a41..94a681802812 100644 --- a/crates/store/re_types/src/components/draw_order.rs +++ b/crates/store/re_types/src/components/draw_order.rs @@ -106,7 +106,7 @@ impl std::ops::DerefMut for DrawOrder { } } -impl ::re_types_core::SizeBytes for DrawOrder { +impl ::re_byte_size::SizeBytes for DrawOrder { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/entity_path.rs b/crates/store/re_types/src/components/entity_path.rs index 4c1b63c5fac6..e6a8b3542415 100644 --- a/crates/store/re_types/src/components/entity_path.rs +++ b/crates/store/re_types/src/components/entity_path.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for EntityPath { } } -impl ::re_types_core::SizeBytes for EntityPath { +impl ::re_byte_size::SizeBytes for EntityPath { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/fill_mode.rs b/crates/store/re_types/src/components/fill_mode.rs index 62626d83d9ed..4c04b9d41705 100644 --- a/crates/store/re_types/src/components/fill_mode.rs +++ b/crates/store/re_types/src/components/fill_mode.rs @@ -167,7 +167,7 @@ impl ::re_types_core::reflection::Enum for FillMode { } } -impl ::re_types_core::SizeBytes for FillMode { +impl ::re_byte_size::SizeBytes for FillMode { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/fill_ratio.rs b/crates/store/re_types/src/components/fill_ratio.rs index 00232aacb8be..bce5ddd70c22 100644 --- a/crates/store/re_types/src/components/fill_ratio.rs +++ b/crates/store/re_types/src/components/fill_ratio.rs @@ -105,7 +105,7 @@ impl std::ops::DerefMut for FillRatio { } } -impl ::re_types_core::SizeBytes for FillRatio { +impl ::re_byte_size::SizeBytes for FillRatio { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/gamma_correction.rs b/crates/store/re_types/src/components/gamma_correction.rs index 2237888deb1f..305ea10ef765 100644 --- a/crates/store/re_types/src/components/gamma_correction.rs +++ b/crates/store/re_types/src/components/gamma_correction.rs @@ -106,7 +106,7 @@ impl std::ops::DerefMut for GammaCorrection { } } -impl ::re_types_core::SizeBytes for GammaCorrection { +impl ::re_byte_size::SizeBytes for GammaCorrection { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/geo_line_string.rs b/crates/store/re_types/src/components/geo_line_string.rs index 09348a64d66f..3c3283cc1e21 100644 --- a/crates/store/re_types/src/components/geo_line_string.rs +++ b/crates/store/re_types/src/components/geo_line_string.rs @@ -251,7 +251,7 @@ impl, T: IntoIterator> From for G } } -impl ::re_types_core::SizeBytes for GeoLineString { +impl ::re_byte_size::SizeBytes for GeoLineString { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/graph_edge.rs b/crates/store/re_types/src/components/graph_edge.rs index 2fb1838a1d5f..282bf47a34ee 100644 --- a/crates/store/re_types/src/components/graph_edge.rs +++ b/crates/store/re_types/src/components/graph_edge.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for GraphEdge { } } -impl ::re_types_core::SizeBytes for GraphEdge { +impl ::re_byte_size::SizeBytes for GraphEdge { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/graph_node.rs b/crates/store/re_types/src/components/graph_node.rs index 89480d1e0983..7e3896b7db1b 100644 --- a/crates/store/re_types/src/components/graph_node.rs +++ b/crates/store/re_types/src/components/graph_node.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for GraphNode { } } -impl ::re_types_core::SizeBytes for GraphNode { +impl ::re_byte_size::SizeBytes for GraphNode { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/graph_type.rs b/crates/store/re_types/src/components/graph_type.rs index 6436a08dc0f9..27bee22f474e 100644 --- a/crates/store/re_types/src/components/graph_type.rs +++ b/crates/store/re_types/src/components/graph_type.rs @@ -143,7 +143,7 @@ impl ::re_types_core::reflection::Enum for GraphType { } } -impl ::re_types_core::SizeBytes for GraphType { +impl ::re_byte_size::SizeBytes for GraphType { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/half_size2d.rs b/crates/store/re_types/src/components/half_size2d.rs index 14d5cb88b206..1e664d0e277c 100644 --- a/crates/store/re_types/src/components/half_size2d.rs +++ b/crates/store/re_types/src/components/half_size2d.rs @@ -105,7 +105,7 @@ impl std::ops::DerefMut for HalfSize2D { } } -impl ::re_types_core::SizeBytes for HalfSize2D { +impl ::re_byte_size::SizeBytes for HalfSize2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/half_size3d.rs b/crates/store/re_types/src/components/half_size3d.rs index 998bf7e53ed7..2882097adea8 100644 --- a/crates/store/re_types/src/components/half_size3d.rs +++ b/crates/store/re_types/src/components/half_size3d.rs @@ -105,7 +105,7 @@ impl std::ops::DerefMut for HalfSize3D { } } -impl ::re_types_core::SizeBytes for HalfSize3D { +impl ::re_byte_size::SizeBytes for HalfSize3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/image_buffer.rs b/crates/store/re_types/src/components/image_buffer.rs index 9d1e41bd2f56..fd3c3443ef97 100644 --- a/crates/store/re_types/src/components/image_buffer.rs +++ b/crates/store/re_types/src/components/image_buffer.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for ImageBuffer { } } -impl ::re_types_core::SizeBytes for ImageBuffer { +impl ::re_byte_size::SizeBytes for ImageBuffer { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/image_format.rs b/crates/store/re_types/src/components/image_format.rs index 2d591a3903d9..708502ec38a0 100644 --- a/crates/store/re_types/src/components/image_format.rs +++ b/crates/store/re_types/src/components/image_format.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for ImageFormat { } } -impl ::re_types_core::SizeBytes for ImageFormat { +impl ::re_byte_size::SizeBytes for ImageFormat { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/image_plane_distance.rs b/crates/store/re_types/src/components/image_plane_distance.rs index 0ff93ed36d56..92033f9629a4 100644 --- a/crates/store/re_types/src/components/image_plane_distance.rs +++ b/crates/store/re_types/src/components/image_plane_distance.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for ImagePlaneDistance { } } -impl ::re_types_core::SizeBytes for ImagePlaneDistance { +impl ::re_byte_size::SizeBytes for ImagePlaneDistance { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/keypoint_id.rs b/crates/store/re_types/src/components/keypoint_id.rs index b8d74796b611..96fe828f6511 100644 --- a/crates/store/re_types/src/components/keypoint_id.rs +++ b/crates/store/re_types/src/components/keypoint_id.rs @@ -117,7 +117,7 @@ impl std::ops::DerefMut for KeypointId { } } -impl ::re_types_core::SizeBytes for KeypointId { +impl ::re_byte_size::SizeBytes for KeypointId { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/lat_lon.rs b/crates/store/re_types/src/components/lat_lon.rs index 3368b23b8b5e..f96d9a2c2bd7 100644 --- a/crates/store/re_types/src/components/lat_lon.rs +++ b/crates/store/re_types/src/components/lat_lon.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for LatLon { } } -impl ::re_types_core::SizeBytes for LatLon { +impl ::re_byte_size::SizeBytes for LatLon { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/length.rs b/crates/store/re_types/src/components/length.rs index 5ca84903e046..ebf8e91dea65 100644 --- a/crates/store/re_types/src/components/length.rs +++ b/crates/store/re_types/src/components/length.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for Length { } } -impl ::re_types_core::SizeBytes for Length { +impl ::re_byte_size::SizeBytes for Length { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/line_strip2d.rs b/crates/store/re_types/src/components/line_strip2d.rs index fcac594ffd8e..8b110c7e4a95 100644 --- a/crates/store/re_types/src/components/line_strip2d.rs +++ b/crates/store/re_types/src/components/line_strip2d.rs @@ -260,7 +260,7 @@ impl, T: IntoIterator> From for Li } } -impl ::re_types_core::SizeBytes for LineStrip2D { +impl ::re_byte_size::SizeBytes for LineStrip2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/line_strip3d.rs b/crates/store/re_types/src/components/line_strip3d.rs index 97e579575bc7..202f521e8ca9 100644 --- a/crates/store/re_types/src/components/line_strip3d.rs +++ b/crates/store/re_types/src/components/line_strip3d.rs @@ -260,7 +260,7 @@ impl, T: IntoIterator> From for Li } } -impl ::re_types_core::SizeBytes for LineStrip3D { +impl ::re_byte_size::SizeBytes for LineStrip3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/magnification_filter.rs b/crates/store/re_types/src/components/magnification_filter.rs index ae48e1ac332c..db126ad5f176 100644 --- a/crates/store/re_types/src/components/magnification_filter.rs +++ b/crates/store/re_types/src/components/magnification_filter.rs @@ -152,7 +152,7 @@ impl ::re_types_core::reflection::Enum for MagnificationFilter { } } -impl ::re_types_core::SizeBytes for MagnificationFilter { +impl ::re_byte_size::SizeBytes for MagnificationFilter { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/marker_shape.rs b/crates/store/re_types/src/components/marker_shape.rs index 2a85ca01bf3f..d30468c65085 100644 --- a/crates/store/re_types/src/components/marker_shape.rs +++ b/crates/store/re_types/src/components/marker_shape.rs @@ -202,7 +202,7 @@ impl ::re_types_core::reflection::Enum for MarkerShape { } } -impl ::re_types_core::SizeBytes for MarkerShape { +impl ::re_byte_size::SizeBytes for MarkerShape { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/marker_size.rs b/crates/store/re_types/src/components/marker_size.rs index a426cc42a194..6d35507047a0 100644 --- a/crates/store/re_types/src/components/marker_size.rs +++ b/crates/store/re_types/src/components/marker_size.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for MarkerSize { } } -impl ::re_types_core::SizeBytes for MarkerSize { +impl ::re_byte_size::SizeBytes for MarkerSize { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/media_type.rs b/crates/store/re_types/src/components/media_type.rs index d8fb05969340..06e687390227 100644 --- a/crates/store/re_types/src/components/media_type.rs +++ b/crates/store/re_types/src/components/media_type.rs @@ -95,7 +95,7 @@ impl std::ops::DerefMut for MediaType { } } -impl ::re_types_core::SizeBytes for MediaType { +impl ::re_byte_size::SizeBytes for MediaType { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/name.rs b/crates/store/re_types/src/components/name.rs index c6c0241188a8..d2ea107e7f2c 100644 --- a/crates/store/re_types/src/components/name.rs +++ b/crates/store/re_types/src/components/name.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for Name { } } -impl ::re_types_core::SizeBytes for Name { +impl ::re_byte_size::SizeBytes for Name { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/opacity.rs b/crates/store/re_types/src/components/opacity.rs index 822156726101..e2345b355e56 100644 --- a/crates/store/re_types/src/components/opacity.rs +++ b/crates/store/re_types/src/components/opacity.rs @@ -103,7 +103,7 @@ impl std::ops::DerefMut for Opacity { } } -impl ::re_types_core::SizeBytes for Opacity { +impl ::re_byte_size::SizeBytes for Opacity { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pinhole_projection.rs b/crates/store/re_types/src/components/pinhole_projection.rs index 61e2bb43aa1d..5f987182e76c 100644 --- a/crates/store/re_types/src/components/pinhole_projection.rs +++ b/crates/store/re_types/src/components/pinhole_projection.rs @@ -109,7 +109,7 @@ impl std::ops::DerefMut for PinholeProjection { } } -impl ::re_types_core::SizeBytes for PinholeProjection { +impl ::re_byte_size::SizeBytes for PinholeProjection { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/plane3d.rs b/crates/store/re_types/src/components/plane3d.rs index 3db060645004..8ce5db2f0939 100644 --- a/crates/store/re_types/src/components/plane3d.rs +++ b/crates/store/re_types/src/components/plane3d.rs @@ -108,7 +108,7 @@ impl std::ops::DerefMut for Plane3D { } } -impl ::re_types_core::SizeBytes for Plane3D { +impl ::re_byte_size::SizeBytes for Plane3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pose_rotation_axis_angle.rs b/crates/store/re_types/src/components/pose_rotation_axis_angle.rs index 3aa09bef378b..0b4d96963497 100644 --- a/crates/store/re_types/src/components/pose_rotation_axis_angle.rs +++ b/crates/store/re_types/src/components/pose_rotation_axis_angle.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for PoseRotationAxisAngle { } } -impl ::re_types_core::SizeBytes for PoseRotationAxisAngle { +impl ::re_byte_size::SizeBytes for PoseRotationAxisAngle { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pose_rotation_quat.rs b/crates/store/re_types/src/components/pose_rotation_quat.rs index 964700df594d..472ad4318ed2 100644 --- a/crates/store/re_types/src/components/pose_rotation_quat.rs +++ b/crates/store/re_types/src/components/pose_rotation_quat.rs @@ -104,7 +104,7 @@ impl std::ops::DerefMut for PoseRotationQuat { } } -impl ::re_types_core::SizeBytes for PoseRotationQuat { +impl ::re_byte_size::SizeBytes for PoseRotationQuat { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pose_scale3d.rs b/crates/store/re_types/src/components/pose_scale3d.rs index 3ef25810010c..63b9d5aefa57 100644 --- a/crates/store/re_types/src/components/pose_scale3d.rs +++ b/crates/store/re_types/src/components/pose_scale3d.rs @@ -104,7 +104,7 @@ impl std::ops::DerefMut for PoseScale3D { } } -impl ::re_types_core::SizeBytes for PoseScale3D { +impl ::re_byte_size::SizeBytes for PoseScale3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pose_transform_mat3x3.rs b/crates/store/re_types/src/components/pose_transform_mat3x3.rs index 2c2f3b9295f8..fb2e7f8dc6f3 100644 --- a/crates/store/re_types/src/components/pose_transform_mat3x3.rs +++ b/crates/store/re_types/src/components/pose_transform_mat3x3.rs @@ -112,7 +112,7 @@ impl std::ops::DerefMut for PoseTransformMat3x3 { } } -impl ::re_types_core::SizeBytes for PoseTransformMat3x3 { +impl ::re_byte_size::SizeBytes for PoseTransformMat3x3 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/pose_translation3d.rs b/crates/store/re_types/src/components/pose_translation3d.rs index efde8a24c595..98a41e42768c 100644 --- a/crates/store/re_types/src/components/pose_translation3d.rs +++ b/crates/store/re_types/src/components/pose_translation3d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for PoseTranslation3D { } } -impl ::re_types_core::SizeBytes for PoseTranslation3D { +impl ::re_byte_size::SizeBytes for PoseTranslation3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/position2d.rs b/crates/store/re_types/src/components/position2d.rs index 94790a01a4f3..901b61bdc089 100644 --- a/crates/store/re_types/src/components/position2d.rs +++ b/crates/store/re_types/src/components/position2d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Position2D { } } -impl ::re_types_core::SizeBytes for Position2D { +impl ::re_byte_size::SizeBytes for Position2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/position3d.rs b/crates/store/re_types/src/components/position3d.rs index 6b89098bfa51..d97127ce4d3e 100644 --- a/crates/store/re_types/src/components/position3d.rs +++ b/crates/store/re_types/src/components/position3d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Position3D { } } -impl ::re_types_core::SizeBytes for Position3D { +impl ::re_byte_size::SizeBytes for Position3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/radius.rs b/crates/store/re_types/src/components/radius.rs index 06b071e198ff..f5b9cee6fbe2 100644 --- a/crates/store/re_types/src/components/radius.rs +++ b/crates/store/re_types/src/components/radius.rs @@ -107,7 +107,7 @@ impl std::ops::DerefMut for Radius { } } -impl ::re_types_core::SizeBytes for Radius { +impl ::re_byte_size::SizeBytes for Radius { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/range1d.rs b/crates/store/re_types/src/components/range1d.rs index 0936cd7685de..8147c35517ce 100644 --- a/crates/store/re_types/src/components/range1d.rs +++ b/crates/store/re_types/src/components/range1d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Range1D { } } -impl ::re_types_core::SizeBytes for Range1D { +impl ::re_byte_size::SizeBytes for Range1D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/recording_uri.rs b/crates/store/re_types/src/components/recording_uri.rs index 4dd097489830..3da69bc2104f 100644 --- a/crates/store/re_types/src/components/recording_uri.rs +++ b/crates/store/re_types/src/components/recording_uri.rs @@ -91,7 +91,7 @@ impl std::ops::DerefMut for RecordingUri { } } -impl ::re_types_core::SizeBytes for RecordingUri { +impl ::re_byte_size::SizeBytes for RecordingUri { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/resolution.rs b/crates/store/re_types/src/components/resolution.rs index 4ac815733c70..9e57bd2c778e 100644 --- a/crates/store/re_types/src/components/resolution.rs +++ b/crates/store/re_types/src/components/resolution.rs @@ -101,7 +101,7 @@ impl std::ops::DerefMut for Resolution { } } -impl ::re_types_core::SizeBytes for Resolution { +impl ::re_byte_size::SizeBytes for Resolution { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/rotation_axis_angle.rs b/crates/store/re_types/src/components/rotation_axis_angle.rs index 21dafdc16441..f5e061f14fd1 100644 --- a/crates/store/re_types/src/components/rotation_axis_angle.rs +++ b/crates/store/re_types/src/components/rotation_axis_angle.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for RotationAxisAngle { } } -impl ::re_types_core::SizeBytes for RotationAxisAngle { +impl ::re_byte_size::SizeBytes for RotationAxisAngle { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/rotation_quat.rs b/crates/store/re_types/src/components/rotation_quat.rs index 0ee536178c0b..de4b197aba42 100644 --- a/crates/store/re_types/src/components/rotation_quat.rs +++ b/crates/store/re_types/src/components/rotation_quat.rs @@ -104,7 +104,7 @@ impl std::ops::DerefMut for RotationQuat { } } -impl ::re_types_core::SizeBytes for RotationQuat { +impl ::re_byte_size::SizeBytes for RotationQuat { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/scalar.rs b/crates/store/re_types/src/components/scalar.rs index 97e1f3e9384e..199dd2184afe 100644 --- a/crates/store/re_types/src/components/scalar.rs +++ b/crates/store/re_types/src/components/scalar.rs @@ -102,7 +102,7 @@ impl std::ops::DerefMut for Scalar { } } -impl ::re_types_core::SizeBytes for Scalar { +impl ::re_byte_size::SizeBytes for Scalar { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/scale3d.rs b/crates/store/re_types/src/components/scale3d.rs index 064c4051c1b5..a85daa64bd8a 100644 --- a/crates/store/re_types/src/components/scale3d.rs +++ b/crates/store/re_types/src/components/scale3d.rs @@ -104,7 +104,7 @@ impl std::ops::DerefMut for Scale3D { } } -impl ::re_types_core::SizeBytes for Scale3D { +impl ::re_byte_size::SizeBytes for Scale3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/show_labels.rs b/crates/store/re_types/src/components/show_labels.rs index 949c39f8967c..483b30d233a6 100644 --- a/crates/store/re_types/src/components/show_labels.rs +++ b/crates/store/re_types/src/components/show_labels.rs @@ -98,7 +98,7 @@ impl std::ops::DerefMut for ShowLabels { } } -impl ::re_types_core::SizeBytes for ShowLabels { +impl ::re_byte_size::SizeBytes for ShowLabels { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/stroke_width.rs b/crates/store/re_types/src/components/stroke_width.rs index 08093d9fab09..ffb236f3828d 100644 --- a/crates/store/re_types/src/components/stroke_width.rs +++ b/crates/store/re_types/src/components/stroke_width.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for StrokeWidth { } } -impl ::re_types_core::SizeBytes for StrokeWidth { +impl ::re_byte_size::SizeBytes for StrokeWidth { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/tensor_data.rs b/crates/store/re_types/src/components/tensor_data.rs index 63d7604643e6..e53747d26b4e 100644 --- a/crates/store/re_types/src/components/tensor_data.rs +++ b/crates/store/re_types/src/components/tensor_data.rs @@ -99,7 +99,7 @@ impl std::ops::DerefMut for TensorData { } } -impl ::re_types_core::SizeBytes for TensorData { +impl ::re_byte_size::SizeBytes for TensorData { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/tensor_dimension_index_selection.rs b/crates/store/re_types/src/components/tensor_dimension_index_selection.rs index 6efd104a5685..dcd249d2f180 100644 --- a/crates/store/re_types/src/components/tensor_dimension_index_selection.rs +++ b/crates/store/re_types/src/components/tensor_dimension_index_selection.rs @@ -98,7 +98,7 @@ impl std::ops::DerefMut for TensorDimensionIndexSelection { } } -impl ::re_types_core::SizeBytes for TensorDimensionIndexSelection { +impl ::re_byte_size::SizeBytes for TensorDimensionIndexSelection { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/tensor_height_dimension.rs b/crates/store/re_types/src/components/tensor_height_dimension.rs index e6d43551fb98..389db3841d7b 100644 --- a/crates/store/re_types/src/components/tensor_height_dimension.rs +++ b/crates/store/re_types/src/components/tensor_height_dimension.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for TensorHeightDimension { } } -impl ::re_types_core::SizeBytes for TensorHeightDimension { +impl ::re_byte_size::SizeBytes for TensorHeightDimension { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/tensor_width_dimension.rs b/crates/store/re_types/src/components/tensor_width_dimension.rs index 1731d8d77924..ecf58d7f135b 100644 --- a/crates/store/re_types/src/components/tensor_width_dimension.rs +++ b/crates/store/re_types/src/components/tensor_width_dimension.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for TensorWidthDimension { } } -impl ::re_types_core::SizeBytes for TensorWidthDimension { +impl ::re_byte_size::SizeBytes for TensorWidthDimension { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/texcoord2d.rs b/crates/store/re_types/src/components/texcoord2d.rs index ff48187042d3..499430d3a922 100644 --- a/crates/store/re_types/src/components/texcoord2d.rs +++ b/crates/store/re_types/src/components/texcoord2d.rs @@ -115,7 +115,7 @@ impl std::ops::DerefMut for Texcoord2D { } } -impl ::re_types_core::SizeBytes for Texcoord2D { +impl ::re_byte_size::SizeBytes for Texcoord2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/text.rs b/crates/store/re_types/src/components/text.rs index eba8cd4c5525..fb0fab1fcc7e 100644 --- a/crates/store/re_types/src/components/text.rs +++ b/crates/store/re_types/src/components/text.rs @@ -92,7 +92,7 @@ impl std::ops::DerefMut for Text { } } -impl ::re_types_core::SizeBytes for Text { +impl ::re_byte_size::SizeBytes for Text { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/text_log_level.rs b/crates/store/re_types/src/components/text_log_level.rs index 991a59b9bb7c..b91cb78d5169 100644 --- a/crates/store/re_types/src/components/text_log_level.rs +++ b/crates/store/re_types/src/components/text_log_level.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for TextLogLevel { } } -impl ::re_types_core::SizeBytes for TextLogLevel { +impl ::re_byte_size::SizeBytes for TextLogLevel { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/transform_mat3x3.rs b/crates/store/re_types/src/components/transform_mat3x3.rs index fc9671de6afc..b6559ba91912 100644 --- a/crates/store/re_types/src/components/transform_mat3x3.rs +++ b/crates/store/re_types/src/components/transform_mat3x3.rs @@ -112,7 +112,7 @@ impl std::ops::DerefMut for TransformMat3x3 { } } -impl ::re_types_core::SizeBytes for TransformMat3x3 { +impl ::re_byte_size::SizeBytes for TransformMat3x3 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/transform_relation.rs b/crates/store/re_types/src/components/transform_relation.rs index 4fcd383ef19d..36f678577e28 100644 --- a/crates/store/re_types/src/components/transform_relation.rs +++ b/crates/store/re_types/src/components/transform_relation.rs @@ -155,7 +155,7 @@ impl ::re_types_core::reflection::Enum for TransformRelation { } } -impl ::re_types_core::SizeBytes for TransformRelation { +impl ::re_byte_size::SizeBytes for TransformRelation { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/components/translation3d.rs b/crates/store/re_types/src/components/translation3d.rs index d7875c9c1724..b7325e859d8f 100644 --- a/crates/store/re_types/src/components/translation3d.rs +++ b/crates/store/re_types/src/components/translation3d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Translation3D { } } -impl ::re_types_core::SizeBytes for Translation3D { +impl ::re_byte_size::SizeBytes for Translation3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/triangle_indices.rs b/crates/store/re_types/src/components/triangle_indices.rs index 1fb197e8c6c0..cc752a9cbc76 100644 --- a/crates/store/re_types/src/components/triangle_indices.rs +++ b/crates/store/re_types/src/components/triangle_indices.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for TriangleIndices { } } -impl ::re_types_core::SizeBytes for TriangleIndices { +impl ::re_byte_size::SizeBytes for TriangleIndices { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/value_range.rs b/crates/store/re_types/src/components/value_range.rs index 9bcd6f464a69..1a7aa1933fd3 100644 --- a/crates/store/re_types/src/components/value_range.rs +++ b/crates/store/re_types/src/components/value_range.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for ValueRange { } } -impl ::re_types_core::SizeBytes for ValueRange { +impl ::re_byte_size::SizeBytes for ValueRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/vector2d.rs b/crates/store/re_types/src/components/vector2d.rs index cdefaf8cc172..26995d32da3d 100644 --- a/crates/store/re_types/src/components/vector2d.rs +++ b/crates/store/re_types/src/components/vector2d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Vector2D { } } -impl ::re_types_core::SizeBytes for Vector2D { +impl ::re_byte_size::SizeBytes for Vector2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/vector3d.rs b/crates/store/re_types/src/components/vector3d.rs index be25aefef481..ea69fe11b9f3 100644 --- a/crates/store/re_types/src/components/vector3d.rs +++ b/crates/store/re_types/src/components/vector3d.rs @@ -100,7 +100,7 @@ impl std::ops::DerefMut for Vector3D { } } -impl ::re_types_core::SizeBytes for Vector3D { +impl ::re_byte_size::SizeBytes for Vector3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/video_timestamp.rs b/crates/store/re_types/src/components/video_timestamp.rs index 4cfdc64bf217..71cb109d9775 100644 --- a/crates/store/re_types/src/components/video_timestamp.rs +++ b/crates/store/re_types/src/components/video_timestamp.rs @@ -101,7 +101,7 @@ impl std::ops::DerefMut for VideoTimestamp { } } -impl ::re_types_core::SizeBytes for VideoTimestamp { +impl ::re_byte_size::SizeBytes for VideoTimestamp { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/components/view_coordinates.rs b/crates/store/re_types/src/components/view_coordinates.rs index dd66f8d5f498..d9223f3eddc2 100644 --- a/crates/store/re_types/src/components/view_coordinates.rs +++ b/crates/store/re_types/src/components/view_coordinates.rs @@ -120,7 +120,7 @@ impl std::ops::DerefMut for ViewCoordinates { } } -impl ::re_types_core::SizeBytes for ViewCoordinates { +impl ::re_byte_size::SizeBytes for ViewCoordinates { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/angle.rs b/crates/store/re_types/src/datatypes/angle.rs index b74b624fb9f9..f734b63d6bd5 100644 --- a/crates/store/re_types/src/datatypes/angle.rs +++ b/crates/store/re_types/src/datatypes/angle.rs @@ -150,7 +150,7 @@ impl From for f32 { } } -impl ::re_types_core::SizeBytes for Angle { +impl ::re_byte_size::SizeBytes for Angle { #[inline] fn heap_size_bytes(&self) -> u64 { self.radians.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/annotation_info.rs b/crates/store/re_types/src/datatypes/annotation_info.rs index 2c40d6bf2938..d9355f461a9d 100644 --- a/crates/store/re_types/src/datatypes/annotation_info.rs +++ b/crates/store/re_types/src/datatypes/annotation_info.rs @@ -310,7 +310,7 @@ impl ::re_types_core::Loggable for AnnotationInfo { } } -impl ::re_types_core::SizeBytes for AnnotationInfo { +impl ::re_byte_size::SizeBytes for AnnotationInfo { #[inline] fn heap_size_bytes(&self) -> u64 { self.id.heap_size_bytes() + self.label.heap_size_bytes() + self.color.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/blob.rs b/crates/store/re_types/src/datatypes/blob.rs index 06e08627da94..c20d338e68c4 100644 --- a/crates/store/re_types/src/datatypes/blob.rs +++ b/crates/store/re_types/src/datatypes/blob.rs @@ -178,7 +178,7 @@ impl From for ::re_types_core::ArrowBuffer { } } -impl ::re_types_core::SizeBytes for Blob { +impl ::re_byte_size::SizeBytes for Blob { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/channel_datatype.rs b/crates/store/re_types/src/datatypes/channel_datatype.rs index 0dc6a7829caf..207871944166 100644 --- a/crates/store/re_types/src/datatypes/channel_datatype.rs +++ b/crates/store/re_types/src/datatypes/channel_datatype.rs @@ -204,7 +204,7 @@ impl ::re_types_core::reflection::Enum for ChannelDatatype { } } -impl ::re_types_core::SizeBytes for ChannelDatatype { +impl ::re_byte_size::SizeBytes for ChannelDatatype { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/datatypes/class_description.rs b/crates/store/re_types/src/datatypes/class_description.rs index b6827410d9b8..48eac2f213b7 100644 --- a/crates/store/re_types/src/datatypes/class_description.rs +++ b/crates/store/re_types/src/datatypes/class_description.rs @@ -455,7 +455,7 @@ impl ::re_types_core::Loggable for ClassDescription { } } -impl ::re_types_core::SizeBytes for ClassDescription { +impl ::re_byte_size::SizeBytes for ClassDescription { #[inline] fn heap_size_bytes(&self) -> u64 { self.info.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/class_description_map_elem.rs b/crates/store/re_types/src/datatypes/class_description_map_elem.rs index 075f3b22301f..c66f96064582 100644 --- a/crates/store/re_types/src/datatypes/class_description_map_elem.rs +++ b/crates/store/re_types/src/datatypes/class_description_map_elem.rs @@ -225,7 +225,7 @@ impl ::re_types_core::Loggable for ClassDescriptionMapElem { } } -impl ::re_types_core::SizeBytes for ClassDescriptionMapElem { +impl ::re_byte_size::SizeBytes for ClassDescriptionMapElem { #[inline] fn heap_size_bytes(&self) -> u64 { self.class_id.heap_size_bytes() + self.class_description.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/class_id.rs b/crates/store/re_types/src/datatypes/class_id.rs index 304ace03f214..3bfe186fb5ab 100644 --- a/crates/store/re_types/src/datatypes/class_id.rs +++ b/crates/store/re_types/src/datatypes/class_id.rs @@ -158,7 +158,7 @@ impl From for u16 { } } -impl ::re_types_core::SizeBytes for ClassId { +impl ::re_byte_size::SizeBytes for ClassId { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/color_model.rs b/crates/store/re_types/src/datatypes/color_model.rs index d7d6414e32da..0822d0214d89 100644 --- a/crates/store/re_types/src/datatypes/color_model.rs +++ b/crates/store/re_types/src/datatypes/color_model.rs @@ -160,7 +160,7 @@ impl ::re_types_core::reflection::Enum for ColorModel { } } -impl ::re_types_core::SizeBytes for ColorModel { +impl ::re_byte_size::SizeBytes for ColorModel { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/datatypes/dvec2d.rs b/crates/store/re_types/src/datatypes/dvec2d.rs index f5d8d0040a22..829ad356ec12 100644 --- a/crates/store/re_types/src/datatypes/dvec2d.rs +++ b/crates/store/re_types/src/datatypes/dvec2d.rs @@ -231,7 +231,7 @@ impl From for [f64; 2usize] { } } -impl ::re_types_core::SizeBytes for DVec2D { +impl ::re_byte_size::SizeBytes for DVec2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/image_format.rs b/crates/store/re_types/src/datatypes/image_format.rs index 1ca28125ab11..da5eaf6ba88c 100644 --- a/crates/store/re_types/src/datatypes/image_format.rs +++ b/crates/store/re_types/src/datatypes/image_format.rs @@ -365,7 +365,7 @@ impl ::re_types_core::Loggable for ImageFormat { } } -impl ::re_types_core::SizeBytes for ImageFormat { +impl ::re_byte_size::SizeBytes for ImageFormat { #[inline] fn heap_size_bytes(&self) -> u64 { self.width.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/keypoint_id.rs b/crates/store/re_types/src/datatypes/keypoint_id.rs index 9923b7950756..965a41afff8e 100644 --- a/crates/store/re_types/src/datatypes/keypoint_id.rs +++ b/crates/store/re_types/src/datatypes/keypoint_id.rs @@ -160,7 +160,7 @@ impl From for u16 { } } -impl ::re_types_core::SizeBytes for KeypointId { +impl ::re_byte_size::SizeBytes for KeypointId { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/keypoint_pair.rs b/crates/store/re_types/src/datatypes/keypoint_pair.rs index d487773cfe2b..af5e6bec63ed 100644 --- a/crates/store/re_types/src/datatypes/keypoint_pair.rs +++ b/crates/store/re_types/src/datatypes/keypoint_pair.rs @@ -234,7 +234,7 @@ impl ::re_types_core::Loggable for KeypointPair { } } -impl ::re_types_core::SizeBytes for KeypointPair { +impl ::re_byte_size::SizeBytes for KeypointPair { #[inline] fn heap_size_bytes(&self) -> u64 { self.keypoint0.heap_size_bytes() + self.keypoint1.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/mat3x3.rs b/crates/store/re_types/src/datatypes/mat3x3.rs index 920ad38a6f7d..91bc806fb4b4 100644 --- a/crates/store/re_types/src/datatypes/mat3x3.rs +++ b/crates/store/re_types/src/datatypes/mat3x3.rs @@ -243,7 +243,7 @@ impl From for [f32; 9usize] { } } -impl ::re_types_core::SizeBytes for Mat3x3 { +impl ::re_byte_size::SizeBytes for Mat3x3 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/mat4x4.rs b/crates/store/re_types/src/datatypes/mat4x4.rs index 45da55ee1117..3dac7affbd42 100644 --- a/crates/store/re_types/src/datatypes/mat4x4.rs +++ b/crates/store/re_types/src/datatypes/mat4x4.rs @@ -243,7 +243,7 @@ impl From for [f32; 16usize] { } } -impl ::re_types_core::SizeBytes for Mat4x4 { +impl ::re_byte_size::SizeBytes for Mat4x4 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/pixel_format.rs b/crates/store/re_types/src/datatypes/pixel_format.rs index 0b7c9aa8301e..241bf6467740 100644 --- a/crates/store/re_types/src/datatypes/pixel_format.rs +++ b/crates/store/re_types/src/datatypes/pixel_format.rs @@ -285,7 +285,7 @@ impl ::re_types_core::reflection::Enum for PixelFormat { } } -impl ::re_types_core::SizeBytes for PixelFormat { +impl ::re_byte_size::SizeBytes for PixelFormat { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/datatypes/plane3d.rs b/crates/store/re_types/src/datatypes/plane3d.rs index 7607453c2349..7ff625b8ffe2 100644 --- a/crates/store/re_types/src/datatypes/plane3d.rs +++ b/crates/store/re_types/src/datatypes/plane3d.rs @@ -239,7 +239,7 @@ impl From for [f32; 4usize] { } } -impl ::re_types_core::SizeBytes for Plane3D { +impl ::re_byte_size::SizeBytes for Plane3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/quaternion.rs b/crates/store/re_types/src/datatypes/quaternion.rs index dde74d4cd6d8..6c3272d3f7b9 100644 --- a/crates/store/re_types/src/datatypes/quaternion.rs +++ b/crates/store/re_types/src/datatypes/quaternion.rs @@ -234,7 +234,7 @@ impl From for [f32; 4usize] { } } -impl ::re_types_core::SizeBytes for Quaternion { +impl ::re_byte_size::SizeBytes for Quaternion { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/range1d.rs b/crates/store/re_types/src/datatypes/range1d.rs index 991fa76b5501..e30aea9ec759 100644 --- a/crates/store/re_types/src/datatypes/range1d.rs +++ b/crates/store/re_types/src/datatypes/range1d.rs @@ -231,7 +231,7 @@ impl From for [f64; 2usize] { } } -impl ::re_types_core::SizeBytes for Range1D { +impl ::re_byte_size::SizeBytes for Range1D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/range2d.rs b/crates/store/re_types/src/datatypes/range2d.rs index 5451895c339b..a8ce00b90d1b 100644 --- a/crates/store/re_types/src/datatypes/range2d.rs +++ b/crates/store/re_types/src/datatypes/range2d.rs @@ -389,7 +389,7 @@ impl ::re_types_core::Loggable for Range2D { } } -impl ::re_types_core::SizeBytes for Range2D { +impl ::re_byte_size::SizeBytes for Range2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.x_range.heap_size_bytes() + self.y_range.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/rgba32.rs b/crates/store/re_types/src/datatypes/rgba32.rs index 8fb26c31b5b6..1c24e06ce8ef 100644 --- a/crates/store/re_types/src/datatypes/rgba32.rs +++ b/crates/store/re_types/src/datatypes/rgba32.rs @@ -148,7 +148,7 @@ impl From for u32 { } } -impl ::re_types_core::SizeBytes for Rgba32 { +impl ::re_byte_size::SizeBytes for Rgba32 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/rotation_axis_angle.rs b/crates/store/re_types/src/datatypes/rotation_axis_angle.rs index 59218e9ced58..c65f22a8881d 100644 --- a/crates/store/re_types/src/datatypes/rotation_axis_angle.rs +++ b/crates/store/re_types/src/datatypes/rotation_axis_angle.rs @@ -302,7 +302,7 @@ impl ::re_types_core::Loggable for RotationAxisAngle { } } -impl ::re_types_core::SizeBytes for RotationAxisAngle { +impl ::re_byte_size::SizeBytes for RotationAxisAngle { #[inline] fn heap_size_bytes(&self) -> u64 { self.axis.heap_size_bytes() + self.angle.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/tensor_buffer.rs b/crates/store/re_types/src/datatypes/tensor_buffer.rs index cf2df863a568..969bf4185a49 100644 --- a/crates/store/re_types/src/datatypes/tensor_buffer.rs +++ b/crates/store/re_types/src/datatypes/tensor_buffer.rs @@ -1725,7 +1725,7 @@ impl ::re_types_core::Loggable for TensorBuffer { } } -impl ::re_types_core::SizeBytes for TensorBuffer { +impl ::re_byte_size::SizeBytes for TensorBuffer { #[inline] fn heap_size_bytes(&self) -> u64 { #![allow(clippy::match_same_arms)] diff --git a/crates/store/re_types/src/datatypes/tensor_data.rs b/crates/store/re_types/src/datatypes/tensor_data.rs index 4d75cc0c12e3..b82c64eb3bcd 100644 --- a/crates/store/re_types/src/datatypes/tensor_data.rs +++ b/crates/store/re_types/src/datatypes/tensor_data.rs @@ -490,7 +490,7 @@ impl ::re_types_core::Loggable for TensorData { } } -impl ::re_types_core::SizeBytes for TensorData { +impl ::re_byte_size::SizeBytes for TensorData { #[inline] fn heap_size_bytes(&self) -> u64 { self.shape.heap_size_bytes() + self.names.heap_size_bytes() + self.buffer.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/tensor_dimension_index_selection.rs b/crates/store/re_types/src/datatypes/tensor_dimension_index_selection.rs index 179947448fcb..06da490978e7 100644 --- a/crates/store/re_types/src/datatypes/tensor_dimension_index_selection.rs +++ b/crates/store/re_types/src/datatypes/tensor_dimension_index_selection.rs @@ -222,7 +222,7 @@ impl ::re_types_core::Loggable for TensorDimensionIndexSelection { } } -impl ::re_types_core::SizeBytes for TensorDimensionIndexSelection { +impl ::re_byte_size::SizeBytes for TensorDimensionIndexSelection { #[inline] fn heap_size_bytes(&self) -> u64 { self.dimension.heap_size_bytes() + self.index.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/tensor_dimension_selection.rs b/crates/store/re_types/src/datatypes/tensor_dimension_selection.rs index cbf750d55342..dbea1d4084e1 100644 --- a/crates/store/re_types/src/datatypes/tensor_dimension_selection.rs +++ b/crates/store/re_types/src/datatypes/tensor_dimension_selection.rs @@ -217,7 +217,7 @@ impl ::re_types_core::Loggable for TensorDimensionSelection { } } -impl ::re_types_core::SizeBytes for TensorDimensionSelection { +impl ::re_byte_size::SizeBytes for TensorDimensionSelection { #[inline] fn heap_size_bytes(&self) -> u64 { self.dimension.heap_size_bytes() + self.invert.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/utf8pair.rs b/crates/store/re_types/src/datatypes/utf8pair.rs index 2eec236d7687..697733297983 100644 --- a/crates/store/re_types/src/datatypes/utf8pair.rs +++ b/crates/store/re_types/src/datatypes/utf8pair.rs @@ -300,7 +300,7 @@ impl ::re_types_core::Loggable for Utf8Pair { } } -impl ::re_types_core::SizeBytes for Utf8Pair { +impl ::re_byte_size::SizeBytes for Utf8Pair { #[inline] fn heap_size_bytes(&self) -> u64 { self.first.heap_size_bytes() + self.second.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/uuid.rs b/crates/store/re_types/src/datatypes/uuid.rs index 56c95a6893b2..90d4e293bd88 100644 --- a/crates/store/re_types/src/datatypes/uuid.rs +++ b/crates/store/re_types/src/datatypes/uuid.rs @@ -238,7 +238,7 @@ impl From for [u8; 16usize] { } } -impl ::re_types_core::SizeBytes for Uuid { +impl ::re_byte_size::SizeBytes for Uuid { #[inline] fn heap_size_bytes(&self) -> u64 { self.bytes.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/uvec2d.rs b/crates/store/re_types/src/datatypes/uvec2d.rs index 73027ab3b0e3..b5610eebd77a 100644 --- a/crates/store/re_types/src/datatypes/uvec2d.rs +++ b/crates/store/re_types/src/datatypes/uvec2d.rs @@ -231,7 +231,7 @@ impl From for [u32; 2usize] { } } -impl ::re_types_core::SizeBytes for UVec2D { +impl ::re_byte_size::SizeBytes for UVec2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/uvec3d.rs b/crates/store/re_types/src/datatypes/uvec3d.rs index c2d0688212c7..0913b1ce9403 100644 --- a/crates/store/re_types/src/datatypes/uvec3d.rs +++ b/crates/store/re_types/src/datatypes/uvec3d.rs @@ -231,7 +231,7 @@ impl From for [u32; 3usize] { } } -impl ::re_types_core::SizeBytes for UVec3D { +impl ::re_byte_size::SizeBytes for UVec3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/uvec4d.rs b/crates/store/re_types/src/datatypes/uvec4d.rs index 1f081982fec9..66316f5a4112 100644 --- a/crates/store/re_types/src/datatypes/uvec4d.rs +++ b/crates/store/re_types/src/datatypes/uvec4d.rs @@ -231,7 +231,7 @@ impl From for [u32; 4usize] { } } -impl ::re_types_core::SizeBytes for UVec4D { +impl ::re_byte_size::SizeBytes for UVec4D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/vec2d.rs b/crates/store/re_types/src/datatypes/vec2d.rs index a50e5b92d935..2efd1694dd50 100644 --- a/crates/store/re_types/src/datatypes/vec2d.rs +++ b/crates/store/re_types/src/datatypes/vec2d.rs @@ -231,7 +231,7 @@ impl From for [f32; 2usize] { } } -impl ::re_types_core::SizeBytes for Vec2D { +impl ::re_byte_size::SizeBytes for Vec2D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/vec3d.rs b/crates/store/re_types/src/datatypes/vec3d.rs index 62f096d2e016..e25df1bc99b4 100644 --- a/crates/store/re_types/src/datatypes/vec3d.rs +++ b/crates/store/re_types/src/datatypes/vec3d.rs @@ -231,7 +231,7 @@ impl From for [f32; 3usize] { } } -impl ::re_types_core::SizeBytes for Vec3D { +impl ::re_byte_size::SizeBytes for Vec3D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/vec4d.rs b/crates/store/re_types/src/datatypes/vec4d.rs index cf04d4da7c20..6c27893d6a7e 100644 --- a/crates/store/re_types/src/datatypes/vec4d.rs +++ b/crates/store/re_types/src/datatypes/vec4d.rs @@ -231,7 +231,7 @@ impl From for [f32; 4usize] { } } -impl ::re_types_core::SizeBytes for Vec4D { +impl ::re_byte_size::SizeBytes for Vec4D { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/video_timestamp.rs b/crates/store/re_types/src/datatypes/video_timestamp.rs index b572e278c1cc..566a4b140d91 100644 --- a/crates/store/re_types/src/datatypes/video_timestamp.rs +++ b/crates/store/re_types/src/datatypes/video_timestamp.rs @@ -148,7 +148,7 @@ impl From for i64 { } } -impl ::re_types_core::SizeBytes for VideoTimestamp { +impl ::re_byte_size::SizeBytes for VideoTimestamp { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/datatypes/view_coordinates.rs b/crates/store/re_types/src/datatypes/view_coordinates.rs index c290c685fc2b..142109ff373e 100644 --- a/crates/store/re_types/src/datatypes/view_coordinates.rs +++ b/crates/store/re_types/src/datatypes/view_coordinates.rs @@ -251,7 +251,7 @@ impl From for [u8; 3usize] { } } -impl ::re_types_core::SizeBytes for ViewCoordinates { +impl ::re_byte_size::SizeBytes for ViewCoordinates { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/archetypes/affix_fuzzer1.rs b/crates/store/re_types/src/testing/archetypes/affix_fuzzer1.rs index 8eed4f39795a..e7d01dd7bdc4 100644 --- a/crates/store/re_types/src/testing/archetypes/affix_fuzzer1.rs +++ b/crates/store/re_types/src/testing/archetypes/affix_fuzzer1.rs @@ -952,7 +952,7 @@ impl AffixFuzzer1 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer1 { +impl ::re_byte_size::SizeBytes for AffixFuzzer1 { #[inline] fn heap_size_bytes(&self) -> u64 { self.fuzz1001.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/archetypes/affix_fuzzer2.rs b/crates/store/re_types/src/testing/archetypes/affix_fuzzer2.rs index 28cb64bfebc6..b0616444125c 100644 --- a/crates/store/re_types/src/testing/archetypes/affix_fuzzer2.rs +++ b/crates/store/re_types/src/testing/archetypes/affix_fuzzer2.rs @@ -822,7 +822,7 @@ impl AffixFuzzer2 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer2 { +impl ::re_byte_size::SizeBytes for AffixFuzzer2 { #[inline] fn heap_size_bytes(&self) -> u64 { self.fuzz1101.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/archetypes/affix_fuzzer3.rs b/crates/store/re_types/src/testing/archetypes/affix_fuzzer3.rs index 643d315ff076..53eef9ac7012 100644 --- a/crates/store/re_types/src/testing/archetypes/affix_fuzzer3.rs +++ b/crates/store/re_types/src/testing/archetypes/affix_fuzzer3.rs @@ -929,7 +929,7 @@ impl AffixFuzzer3 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer3 { +impl ::re_byte_size::SizeBytes for AffixFuzzer3 { #[inline] fn heap_size_bytes(&self) -> u64 { self.fuzz2001.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/archetypes/affix_fuzzer4.rs b/crates/store/re_types/src/testing/archetypes/affix_fuzzer4.rs index e3f2d70e7783..bd411f580fca 100644 --- a/crates/store/re_types/src/testing/archetypes/affix_fuzzer4.rs +++ b/crates/store/re_types/src/testing/archetypes/affix_fuzzer4.rs @@ -983,7 +983,7 @@ impl AffixFuzzer4 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer4 { +impl ::re_byte_size::SizeBytes for AffixFuzzer4 { #[inline] fn heap_size_bytes(&self) -> u64 { self.fuzz2101.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer1.rs b/crates/store/re_types/src/testing/components/affix_fuzzer1.rs index 967ddc99930a..e79e819642d1 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer1.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer1.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer1 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer1 { +impl ::re_byte_size::SizeBytes for AffixFuzzer1 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer10.rs b/crates/store/re_types/src/testing/components/affix_fuzzer10.rs index 739d7de755cc..aab96f36261f 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer10.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer10.rs @@ -171,7 +171,7 @@ impl std::ops::DerefMut for AffixFuzzer10 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer10 { +impl ::re_byte_size::SizeBytes for AffixFuzzer10 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer11.rs b/crates/store/re_types/src/testing/components/affix_fuzzer11.rs index 142b2b88218f..be9d6fd364f4 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer11.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer11.rs @@ -199,7 +199,7 @@ impl std::ops::DerefMut for AffixFuzzer11 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer11 { +impl ::re_byte_size::SizeBytes for AffixFuzzer11 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer12.rs b/crates/store/re_types/src/testing/components/affix_fuzzer12.rs index e3f13d3a9d4b..cd951d328af3 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer12.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer12.rs @@ -241,7 +241,7 @@ impl std::ops::DerefMut for AffixFuzzer12 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer12 { +impl ::re_byte_size::SizeBytes for AffixFuzzer12 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer13.rs b/crates/store/re_types/src/testing/components/affix_fuzzer13.rs index 9118de31e42a..7d2864b90119 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer13.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer13.rs @@ -241,7 +241,7 @@ impl std::ops::DerefMut for AffixFuzzer13 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer13 { +impl ::re_byte_size::SizeBytes for AffixFuzzer13 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer14.rs b/crates/store/re_types/src/testing/components/affix_fuzzer14.rs index 9e3e6dd8afdd..e594a1b56f28 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer14.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer14.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer14 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer14 { +impl ::re_byte_size::SizeBytes for AffixFuzzer14 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer15.rs b/crates/store/re_types/src/testing/components/affix_fuzzer15.rs index 674d8a6eb4cd..dea464edf057 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer15.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer15.rs @@ -147,7 +147,7 @@ impl std::ops::DerefMut for AffixFuzzer15 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer15 { +impl ::re_byte_size::SizeBytes for AffixFuzzer15 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer16.rs b/crates/store/re_types/src/testing/components/affix_fuzzer16.rs index 605c7831b803..17ea4f0a2439 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer16.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer16.rs @@ -171,7 +171,7 @@ impl, T: IntoIterator } } -impl ::re_types_core::SizeBytes for AffixFuzzer16 { +impl ::re_byte_size::SizeBytes for AffixFuzzer16 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer17.rs b/crates/store/re_types/src/testing/components/affix_fuzzer17.rs index 5c3584825e37..01785040e053 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer17.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer17.rs @@ -171,7 +171,7 @@ impl, T: IntoIterator } } -impl ::re_types_core::SizeBytes for AffixFuzzer17 { +impl ::re_byte_size::SizeBytes for AffixFuzzer17 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer18.rs b/crates/store/re_types/src/testing/components/affix_fuzzer18.rs index 0ee06f26d382..1ff54d4283a2 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer18.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer18.rs @@ -171,7 +171,7 @@ impl, T: IntoIterator } } -impl ::re_types_core::SizeBytes for AffixFuzzer18 { +impl ::re_byte_size::SizeBytes for AffixFuzzer18 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer19.rs b/crates/store/re_types/src/testing/components/affix_fuzzer19.rs index 1a5b51bc9069..3c420ca8ad4e 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer19.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer19.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer19 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer19 { +impl ::re_byte_size::SizeBytes for AffixFuzzer19 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer2.rs b/crates/store/re_types/src/testing/components/affix_fuzzer2.rs index 32e9c765e816..bdffe830be6a 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer2.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer2.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer2 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer2 { +impl ::re_byte_size::SizeBytes for AffixFuzzer2 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer20.rs b/crates/store/re_types/src/testing/components/affix_fuzzer20.rs index 03d4e6af555b..1834ea677a5c 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer20.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer20.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer20 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer20 { +impl ::re_byte_size::SizeBytes for AffixFuzzer20 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer21.rs b/crates/store/re_types/src/testing/components/affix_fuzzer21.rs index 1455cba6c48a..23e9ed8570a1 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer21.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer21.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer21 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer21 { +impl ::re_byte_size::SizeBytes for AffixFuzzer21 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer22.rs b/crates/store/re_types/src/testing/components/affix_fuzzer22.rs index 7e74d392baaf..df21c991ddf8 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer22.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer22.rs @@ -127,7 +127,7 @@ impl std::ops::DerefMut for AffixFuzzer22 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer22 { +impl ::re_byte_size::SizeBytes for AffixFuzzer22 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer23.rs b/crates/store/re_types/src/testing/components/affix_fuzzer23.rs index 9ece4182d69c..11deefca4235 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer23.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer23.rs @@ -131,7 +131,7 @@ impl std::ops::DerefMut for AffixFuzzer23 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer23 { +impl ::re_byte_size::SizeBytes for AffixFuzzer23 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer3.rs b/crates/store/re_types/src/testing/components/affix_fuzzer3.rs index 3dc4948654ae..8ee77d150818 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer3.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer3.rs @@ -90,7 +90,7 @@ impl std::ops::DerefMut for AffixFuzzer3 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer3 { +impl ::re_byte_size::SizeBytes for AffixFuzzer3 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer4.rs b/crates/store/re_types/src/testing/components/affix_fuzzer4.rs index 0759fa56d94f..fa4e37a359f4 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer4.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer4.rs @@ -158,7 +158,7 @@ impl std::ops::DerefMut for AffixFuzzer4 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer4 { +impl ::re_byte_size::SizeBytes for AffixFuzzer4 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer5.rs b/crates/store/re_types/src/testing/components/affix_fuzzer5.rs index d86667953fd2..ac54a75b99ac 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer5.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer5.rs @@ -158,7 +158,7 @@ impl std::ops::DerefMut for AffixFuzzer5 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer5 { +impl ::re_byte_size::SizeBytes for AffixFuzzer5 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer6.rs b/crates/store/re_types/src/testing/components/affix_fuzzer6.rs index 119e829355e7..0ef3c818dcff 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer6.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer6.rs @@ -158,7 +158,7 @@ impl std::ops::DerefMut for AffixFuzzer6 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer6 { +impl ::re_byte_size::SizeBytes for AffixFuzzer6 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer7.rs b/crates/store/re_types/src/testing/components/affix_fuzzer7.rs index 74fa0a201a01..0c5ad27bf2c6 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer7.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer7.rs @@ -169,7 +169,7 @@ impl, T: IntoIterator } } -impl ::re_types_core::SizeBytes for AffixFuzzer7 { +impl ::re_byte_size::SizeBytes for AffixFuzzer7 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer8.rs b/crates/store/re_types/src/testing/components/affix_fuzzer8.rs index 9bbec3a8735f..ba60138bdc3a 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer8.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer8.rs @@ -132,7 +132,7 @@ impl std::ops::DerefMut for AffixFuzzer8 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer8 { +impl ::re_byte_size::SizeBytes for AffixFuzzer8 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/components/affix_fuzzer9.rs b/crates/store/re_types/src/testing/components/affix_fuzzer9.rs index a5d0d98442cd..04501462b78c 100644 --- a/crates/store/re_types/src/testing/components/affix_fuzzer9.rs +++ b/crates/store/re_types/src/testing/components/affix_fuzzer9.rs @@ -171,7 +171,7 @@ impl std::ops::DerefMut for AffixFuzzer9 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer9 { +impl ::re_byte_size::SizeBytes for AffixFuzzer9 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer1.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer1.rs index 4cec3891a667..01fb9cba7b26 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer1.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer1.rs @@ -1069,7 +1069,7 @@ impl ::re_types_core::Loggable for AffixFuzzer1 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer1 { +impl ::re_byte_size::SizeBytes for AffixFuzzer1 { #[inline] fn heap_size_bytes(&self) -> u64 { self.single_float_optional.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer2.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer2.rs index 07e674e03429..a0c510288c6e 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer2.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer2.rs @@ -109,7 +109,7 @@ impl From for Option { } } -impl ::re_types_core::SizeBytes for AffixFuzzer2 { +impl ::re_byte_size::SizeBytes for AffixFuzzer2 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer20.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer20.rs index 36adf314259f..7db553025d94 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer20.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer20.rs @@ -272,7 +272,7 @@ impl ::re_types_core::Loggable for AffixFuzzer20 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer20 { +impl ::re_byte_size::SizeBytes for AffixFuzzer20 { #[inline] fn heap_size_bytes(&self) -> u64 { self.p.heap_size_bytes() + self.s.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer21.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer21.rs index aa6cac91defd..851c579b5bc3 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer21.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer21.rs @@ -300,7 +300,7 @@ impl ::re_types_core::Loggable for AffixFuzzer21 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer21 { +impl ::re_byte_size::SizeBytes for AffixFuzzer21 { #[inline] fn heap_size_bytes(&self) -> u64 { self.single_half.heap_size_bytes() + self.many_halves.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer22.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer22.rs index 1edab45a0dd6..3482fc1ffba4 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer22.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer22.rs @@ -268,7 +268,7 @@ impl From for [u8; 4usize] { } } -impl ::re_types_core::SizeBytes for AffixFuzzer22 { +impl ::re_byte_size::SizeBytes for AffixFuzzer22 { #[inline] fn heap_size_bytes(&self) -> u64 { self.fixed_sized_native.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer3.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer3.rs index b43ce063aba7..b41e7a386323 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer3.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer3.rs @@ -554,7 +554,7 @@ impl ::re_types_core::Loggable for AffixFuzzer3 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer3 { +impl ::re_byte_size::SizeBytes for AffixFuzzer3 { #[inline] fn heap_size_bytes(&self) -> u64 { #![allow(clippy::match_same_arms)] diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer4.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer4.rs index bc763821d865..a879342c4e4b 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer4.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer4.rs @@ -367,7 +367,7 @@ impl ::re_types_core::Loggable for AffixFuzzer4 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer4 { +impl ::re_byte_size::SizeBytes for AffixFuzzer4 { #[inline] fn heap_size_bytes(&self) -> u64 { #![allow(clippy::match_same_arms)] diff --git a/crates/store/re_types/src/testing/datatypes/affix_fuzzer5.rs b/crates/store/re_types/src/testing/datatypes/affix_fuzzer5.rs index 7eff68520d75..95623ef02530 100644 --- a/crates/store/re_types/src/testing/datatypes/affix_fuzzer5.rs +++ b/crates/store/re_types/src/testing/datatypes/affix_fuzzer5.rs @@ -186,7 +186,7 @@ impl std::ops::DerefMut for AffixFuzzer5 { } } -impl ::re_types_core::SizeBytes for AffixFuzzer5 { +impl ::re_byte_size::SizeBytes for AffixFuzzer5 { #[inline] fn heap_size_bytes(&self) -> u64 { self.single_optional_union.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/enum_test.rs b/crates/store/re_types/src/testing/datatypes/enum_test.rs index b0cab6ff3021..4eb6a39dbc43 100644 --- a/crates/store/re_types/src/testing/datatypes/enum_test.rs +++ b/crates/store/re_types/src/testing/datatypes/enum_test.rs @@ -167,7 +167,7 @@ impl ::re_types_core::reflection::Enum for EnumTest { } } -impl ::re_types_core::SizeBytes for EnumTest { +impl ::re_byte_size::SizeBytes for EnumTest { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types/src/testing/datatypes/flattened_scalar.rs b/crates/store/re_types/src/testing/datatypes/flattened_scalar.rs index 596b7a54dc9a..2cf2dc3b3930 100644 --- a/crates/store/re_types/src/testing/datatypes/flattened_scalar.rs +++ b/crates/store/re_types/src/testing/datatypes/flattened_scalar.rs @@ -175,7 +175,7 @@ impl From for f32 { } } -impl ::re_types_core::SizeBytes for FlattenedScalar { +impl ::re_byte_size::SizeBytes for FlattenedScalar { #[inline] fn heap_size_bytes(&self) -> u64 { self.value.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/multi_enum.rs b/crates/store/re_types/src/testing/datatypes/multi_enum.rs index 0551435fa8da..682f9fb50147 100644 --- a/crates/store/re_types/src/testing/datatypes/multi_enum.rs +++ b/crates/store/re_types/src/testing/datatypes/multi_enum.rs @@ -204,7 +204,7 @@ impl ::re_types_core::Loggable for MultiEnum { } } -impl ::re_types_core::SizeBytes for MultiEnum { +impl ::re_byte_size::SizeBytes for MultiEnum { #[inline] fn heap_size_bytes(&self) -> u64 { self.value1.heap_size_bytes() + self.value2.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/primitive_component.rs b/crates/store/re_types/src/testing/datatypes/primitive_component.rs index 2271cc2e2c7c..fba864edf08c 100644 --- a/crates/store/re_types/src/testing/datatypes/primitive_component.rs +++ b/crates/store/re_types/src/testing/datatypes/primitive_component.rs @@ -142,7 +142,7 @@ impl From for u32 { } } -impl ::re_types_core::SizeBytes for PrimitiveComponent { +impl ::re_byte_size::SizeBytes for PrimitiveComponent { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/string_component.rs b/crates/store/re_types/src/testing/datatypes/string_component.rs index 735ff75abb84..f2a4dec25b7a 100644 --- a/crates/store/re_types/src/testing/datatypes/string_component.rs +++ b/crates/store/re_types/src/testing/datatypes/string_component.rs @@ -149,7 +149,7 @@ impl From for ::re_types_core::ArrowString { } } -impl ::re_types_core::SizeBytes for StringComponent { +impl ::re_byte_size::SizeBytes for StringComponent { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types/src/testing/datatypes/valued_enum.rs b/crates/store/re_types/src/testing/datatypes/valued_enum.rs index 90aeab7fbdb4..552bc6f849e3 100644 --- a/crates/store/re_types/src/testing/datatypes/valued_enum.rs +++ b/crates/store/re_types/src/testing/datatypes/valued_enum.rs @@ -147,7 +147,7 @@ impl ::re_types_core::reflection::Enum for ValuedEnum { } } -impl ::re_types_core::SizeBytes for ValuedEnum { +impl ::re_byte_size::SizeBytes for ValuedEnum { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types_core/Cargo.toml b/crates/store/re_types_core/Cargo.toml index 71b15bcd42a9..93b4cfc65bac 100644 --- a/crates/store/re_types_core/Cargo.toml +++ b/crates/store/re_types_core/Cargo.toml @@ -36,6 +36,7 @@ serde = ["dep:serde", "re_string_interner/serde"] # Rerun re_case.workspace = true re_error.workspace = true +re_byte_size.workspace = true re_string_interner.workspace = true re_tracing.workspace = true re_tuid.workspace = true @@ -52,11 +53,9 @@ arrow2 = { workspace = true, features = [ backtrace.workspace = true bytemuck.workspace = true document-features.workspace = true -half.workspace = true itertools.workspace = true nohash-hasher.workspace = true once_cell.workspace = true -smallvec.workspace = true thiserror.workspace = true # Optional dependencies diff --git a/crates/store/re_types_core/src/archetype.rs b/crates/store/re_types_core/src/archetype.rs index 601684ef68fb..525cc3b8f731 100644 --- a/crates/store/re_types_core/src/archetype.rs +++ b/crates/store/re_types_core/src/archetype.rs @@ -210,7 +210,7 @@ impl ArchetypeName { } } -impl crate::SizeBytes for ArchetypeName { +impl re_byte_size::SizeBytes for ArchetypeName { #[inline] fn heap_size_bytes(&self) -> u64 { 0 @@ -224,7 +224,7 @@ re_string_interner::declare_new_type!( pub struct ArchetypeFieldName; ); -impl crate::SizeBytes for ArchetypeFieldName { +impl re_byte_size::SizeBytes for ArchetypeFieldName { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types_core/src/archetypes/clear.rs b/crates/store/re_types_core/src/archetypes/clear.rs index 019572ddf0ae..1a93036595bf 100644 --- a/crates/store/re_types_core/src/archetypes/clear.rs +++ b/crates/store/re_types_core/src/archetypes/clear.rs @@ -224,7 +224,7 @@ impl Clear { } } -impl crate::SizeBytes for Clear { +impl ::re_byte_size::SizeBytes for Clear { #[inline] fn heap_size_bytes(&self) -> u64 { self.is_recursive.heap_size_bytes() diff --git a/crates/store/re_types_core/src/arrow_buffer.rs b/crates/store/re_types_core/src/arrow_buffer.rs index a07e47ca2e88..042e239464a1 100644 --- a/crates/store/re_types_core/src/arrow_buffer.rs +++ b/crates/store/re_types_core/src/arrow_buffer.rs @@ -1,4 +1,5 @@ use arrow::datatypes::ArrowNativeType; +use re_byte_size::SizeBytes; /// Convenience-wrapper around an [`arrow::buffer::ScalarBuffer`] that is known to contain a /// a primitive type. @@ -17,7 +18,7 @@ impl Default for ArrowBuffer { } } -impl crate::SizeBytes for ArrowBuffer { +impl SizeBytes for ArrowBuffer { #[inline] fn heap_size_bytes(&self) -> u64 { std::mem::size_of_val(self.as_slice()) as _ diff --git a/crates/store/re_types_core/src/arrow_string.rs b/crates/store/re_types_core/src/arrow_string.rs index 8376167d8deb..426202108100 100644 --- a/crates/store/re_types_core/src/arrow_string.rs +++ b/crates/store/re_types_core/src/arrow_string.rs @@ -11,7 +11,7 @@ use arrow2::buffer::Buffer; #[derive(Clone, Debug, Default)] pub struct ArrowString(Buffer); -impl crate::SizeBytes for ArrowString { +impl re_byte_size::SizeBytes for ArrowString { #[inline] fn heap_size_bytes(&self) -> u64 { let Self(buf) = self; diff --git a/crates/store/re_types_core/src/component_descriptor.rs b/crates/store/re_types_core/src/component_descriptor.rs index 0d0d10c6cf45..cf19c2d437e4 100644 --- a/crates/store/re_types_core/src/component_descriptor.rs +++ b/crates/store/re_types_core/src/component_descriptor.rs @@ -1,6 +1,6 @@ use std::borrow::Cow; -use crate::{ArchetypeFieldName, ArchetypeName, ComponentName, SizeBytes}; +use crate::{ArchetypeFieldName, ArchetypeName, ComponentName}; /// A [`ComponentDescriptor`] fully describes the semantics of a column of data. /// @@ -117,7 +117,7 @@ impl ComponentDescriptor { } } -impl SizeBytes for ComponentDescriptor { +impl re_byte_size::SizeBytes for ComponentDescriptor { #[inline] fn heap_size_bytes(&self) -> u64 { let Self { diff --git a/crates/store/re_types_core/src/components/clear_is_recursive.rs b/crates/store/re_types_core/src/components/clear_is_recursive.rs index 1f14d48d8a12..383c43d26a00 100644 --- a/crates/store/re_types_core/src/components/clear_is_recursive.rs +++ b/crates/store/re_types_core/src/components/clear_is_recursive.rs @@ -94,7 +94,7 @@ impl std::ops::DerefMut for ClearIsRecursive { } } -impl crate::SizeBytes for ClearIsRecursive { +impl ::re_byte_size::SizeBytes for ClearIsRecursive { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/bool.rs b/crates/store/re_types_core/src/datatypes/bool.rs index 1d9abe40b882..84ee298a244f 100644 --- a/crates/store/re_types_core/src/datatypes/bool.rs +++ b/crates/store/re_types_core/src/datatypes/bool.rs @@ -110,7 +110,7 @@ impl From for bool { } } -impl crate::SizeBytes for Bool { +impl ::re_byte_size::SizeBytes for Bool { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/entity_path.rs b/crates/store/re_types_core/src/datatypes/entity_path.rs index 52690454d531..90a9829726b4 100644 --- a/crates/store/re_types_core/src/datatypes/entity_path.rs +++ b/crates/store/re_types_core/src/datatypes/entity_path.rs @@ -149,7 +149,7 @@ impl From for crate::ArrowString { } } -impl crate::SizeBytes for EntityPath { +impl ::re_byte_size::SizeBytes for EntityPath { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/float32.rs b/crates/store/re_types_core/src/datatypes/float32.rs index 194c3fd0fe1d..25dd8b95bd21 100644 --- a/crates/store/re_types_core/src/datatypes/float32.rs +++ b/crates/store/re_types_core/src/datatypes/float32.rs @@ -143,7 +143,7 @@ impl From for f32 { } } -impl crate::SizeBytes for Float32 { +impl ::re_byte_size::SizeBytes for Float32 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/float64.rs b/crates/store/re_types_core/src/datatypes/float64.rs index c83beb229b67..142918745bb5 100644 --- a/crates/store/re_types_core/src/datatypes/float64.rs +++ b/crates/store/re_types_core/src/datatypes/float64.rs @@ -143,7 +143,7 @@ impl From for f64 { } } -impl crate::SizeBytes for Float64 { +impl ::re_byte_size::SizeBytes for Float64 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/time_int.rs b/crates/store/re_types_core/src/datatypes/time_int.rs index 9235eff61fe6..b64e38c6f3ef 100644 --- a/crates/store/re_types_core/src/datatypes/time_int.rs +++ b/crates/store/re_types_core/src/datatypes/time_int.rs @@ -142,7 +142,7 @@ impl From for i64 { } } -impl crate::SizeBytes for TimeInt { +impl ::re_byte_size::SizeBytes for TimeInt { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/time_range.rs b/crates/store/re_types_core/src/datatypes/time_range.rs index 770c206fea6e..ca6c88f96fe0 100644 --- a/crates/store/re_types_core/src/datatypes/time_range.rs +++ b/crates/store/re_types_core/src/datatypes/time_range.rs @@ -206,7 +206,7 @@ impl crate::Loggable for TimeRange { } } -impl crate::SizeBytes for TimeRange { +impl ::re_byte_size::SizeBytes for TimeRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.start.heap_size_bytes() + self.end.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/time_range_boundary.rs b/crates/store/re_types_core/src/datatypes/time_range_boundary.rs index 92b12ba1ca91..b4e405c8ce8f 100644 --- a/crates/store/re_types_core/src/datatypes/time_range_boundary.rs +++ b/crates/store/re_types_core/src/datatypes/time_range_boundary.rs @@ -333,7 +333,7 @@ impl crate::Loggable for TimeRangeBoundary { } } -impl crate::SizeBytes for TimeRangeBoundary { +impl ::re_byte_size::SizeBytes for TimeRangeBoundary { #[inline] fn heap_size_bytes(&self) -> u64 { #![allow(clippy::match_same_arms)] diff --git a/crates/store/re_types_core/src/datatypes/uint16.rs b/crates/store/re_types_core/src/datatypes/uint16.rs index 5320d9777e41..8994515dec97 100644 --- a/crates/store/re_types_core/src/datatypes/uint16.rs +++ b/crates/store/re_types_core/src/datatypes/uint16.rs @@ -142,7 +142,7 @@ impl From for u16 { } } -impl crate::SizeBytes for UInt16 { +impl ::re_byte_size::SizeBytes for UInt16 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/uint32.rs b/crates/store/re_types_core/src/datatypes/uint32.rs index 0c11c36b0c8b..391c65290a7b 100644 --- a/crates/store/re_types_core/src/datatypes/uint32.rs +++ b/crates/store/re_types_core/src/datatypes/uint32.rs @@ -142,7 +142,7 @@ impl From for u32 { } } -impl crate::SizeBytes for UInt32 { +impl ::re_byte_size::SizeBytes for UInt32 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/uint64.rs b/crates/store/re_types_core/src/datatypes/uint64.rs index 4a78e89ee499..bfd61034cec9 100644 --- a/crates/store/re_types_core/src/datatypes/uint64.rs +++ b/crates/store/re_types_core/src/datatypes/uint64.rs @@ -142,7 +142,7 @@ impl From for u64 { } } -impl crate::SizeBytes for UInt64 { +impl ::re_byte_size::SizeBytes for UInt64 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/utf8.rs b/crates/store/re_types_core/src/datatypes/utf8.rs index 79e3fe46b16e..cb8600b68f1b 100644 --- a/crates/store/re_types_core/src/datatypes/utf8.rs +++ b/crates/store/re_types_core/src/datatypes/utf8.rs @@ -149,7 +149,7 @@ impl From for crate::ArrowString { } } -impl crate::SizeBytes for Utf8 { +impl ::re_byte_size::SizeBytes for Utf8 { #[inline] fn heap_size_bytes(&self) -> u64 { self.0.heap_size_bytes() diff --git a/crates/store/re_types_core/src/datatypes/visible_time_range.rs b/crates/store/re_types_core/src/datatypes/visible_time_range.rs index 91e470e85a07..a93fd89771cb 100644 --- a/crates/store/re_types_core/src/datatypes/visible_time_range.rs +++ b/crates/store/re_types_core/src/datatypes/visible_time_range.rs @@ -260,7 +260,7 @@ impl crate::Loggable for VisibleTimeRange { } } -impl crate::SizeBytes for VisibleTimeRange { +impl ::re_byte_size::SizeBytes for VisibleTimeRange { #[inline] fn heap_size_bytes(&self) -> u64 { self.timeline.heap_size_bytes() + self.range.heap_size_bytes() diff --git a/crates/store/re_types_core/src/lib.rs b/crates/store/re_types_core/src/lib.rs index 77ded5215d26..52fb0659c524 100644 --- a/crates/store/re_types_core/src/lib.rs +++ b/crates/store/re_types_core/src/lib.rs @@ -246,7 +246,6 @@ mod loggable; mod loggable_batch; pub mod reflection; mod result; -mod size_bytes; mod tuid; mod view; @@ -269,7 +268,6 @@ pub use self::{ DeserializationError, DeserializationResult, ResultExt, SerializationError, SerializationResult, _Backtrace, }, - size_bytes::SizeBytes, view::{View, ViewClassIdentifier}, }; diff --git a/crates/store/re_types_core/src/loggable.rs b/crates/store/re_types_core/src/loggable.rs index 0da30c5acc11..5ab91d59a8bd 100644 --- a/crates/store/re_types_core/src/loggable.rs +++ b/crates/store/re_types_core/src/loggable.rs @@ -2,9 +2,9 @@ use std::borrow::Cow; use nohash_hasher::IntSet; -use crate::{ - result::_Backtrace, ComponentDescriptor, DeserializationResult, SerializationResult, SizeBytes, -}; +use re_byte_size::SizeBytes; + +use crate::{result::_Backtrace, ComponentDescriptor, DeserializationResult, SerializationResult}; #[allow(unused_imports)] // used in docstrings use crate::{Archetype, ComponentBatch, LoggableBatch}; @@ -295,7 +295,7 @@ impl ComponentName { // --- -impl crate::SizeBytes for ComponentName { +impl re_byte_size::SizeBytes for ComponentName { #[inline] fn heap_size_bytes(&self) -> u64 { 0 @@ -337,7 +337,7 @@ impl DatatypeName { } } -impl crate::SizeBytes for DatatypeName { +impl re_byte_size::SizeBytes for DatatypeName { #[inline] fn heap_size_bytes(&self) -> u64 { 0 diff --git a/crates/store/re_types_core/src/size_bytes/mod.rs b/crates/store/re_types_core/src/size_bytes/mod.rs deleted file mode 100644 index a746ada41f39..000000000000 --- a/crates/store/re_types_core/src/size_bytes/mod.rs +++ /dev/null @@ -1,270 +0,0 @@ -mod arrow2_sizes; -mod arrow_sizes; - -use std::collections::{BTreeMap, BTreeSet, HashMap, VecDeque}; -use std::sync::Arc; - -use smallvec::SmallVec; - -// --- - -/// Approximations of stack and heap size for both internal and external types. -/// -/// Motly used for statistics and triggering events such as garbage collection. -pub trait SizeBytes { - /// Returns the total size of `self` in bytes, accounting for both stack and heap space. - #[inline] - fn total_size_bytes(&self) -> u64 { - self.stack_size_bytes() + self.heap_size_bytes() - } - - /// Returns the total size of `self` on the stack, in bytes. - /// - /// Defaults to `std::mem::size_of_val(self)`. - #[inline] - fn stack_size_bytes(&self) -> u64 { - std::mem::size_of_val(self) as _ - } - - /// Returns the total size of `self` on the heap, in bytes. - fn heap_size_bytes(&self) -> u64; - - /// Is `Self` just plain old data? - /// - /// If `true`, this will make most blanket implementations of `SizeBytes` much faster (e.g. `Vec`). - #[inline] - fn is_pod() -> bool { - false - } -} - -// TODO(rust-lang/rust#31844): This isn't happening without specialization. -// impl SizeBytes for T where T: bytemuck::Pod { … } - -// --- Std --- - -impl SizeBytes for String { - /// Does not take capacity into account. - #[inline] - fn heap_size_bytes(&self) -> u64 { - self.as_bytes().len() as u64 - } -} - -impl SizeBytes for BTreeMap { - #[inline] - fn heap_size_bytes(&self) -> u64 { - // NOTE: It's all on the heap at this point. - - let keys_size_bytes = if K::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.keys().map(SizeBytes::total_size_bytes).sum::() - }; - - let values_size_bytes = if V::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.values().map(SizeBytes::total_size_bytes).sum::() - }; - - keys_size_bytes + values_size_bytes - } -} - -impl SizeBytes for BTreeSet { - #[inline] - fn heap_size_bytes(&self) -> u64 { - // NOTE: It's all on the heap at this point. - - if K::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.iter().map(SizeBytes::total_size_bytes).sum::() - } - } -} - -impl SizeBytes for HashMap { - #[inline] - fn heap_size_bytes(&self) -> u64 { - // NOTE: It's all on the heap at this point. - - let keys_size_bytes = if K::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.keys().map(SizeBytes::total_size_bytes).sum::() - }; - - let values_size_bytes = if V::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.values().map(SizeBytes::total_size_bytes).sum::() - }; - - keys_size_bytes + values_size_bytes - } -} - -// NOTE: Do _not_ implement `SizeBytes` for slices: we cannot know whether they point to the stack -// or the heap! - -impl SizeBytes for [T; N] { - #[inline] - fn heap_size_bytes(&self) -> u64 { - if T::is_pod() { - 0 // it's a const-sized array - } else { - self.iter().map(SizeBytes::heap_size_bytes).sum::() - } - } -} - -impl SizeBytes for Vec { - /// Does not take capacity into account. - #[inline] - fn heap_size_bytes(&self) -> u64 { - // NOTE: It's all on the heap at this point. - if T::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.iter().map(SizeBytes::total_size_bytes).sum::() - } - } -} - -impl SizeBytes for VecDeque { - /// Does not take capacity into account. - #[inline] - fn heap_size_bytes(&self) -> u64 { - // NOTE: It's all on the heap at this point. - if T::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.iter().map(SizeBytes::total_size_bytes).sum::() - } - } -} - -impl SizeBytes for SmallVec<[T; N]> { - /// Does not take capacity into account. - #[inline] - fn heap_size_bytes(&self) -> u64 { - if self.len() <= N { - // The `SmallVec` is still smaller than the threshold so no heap data has been - // allocated yet, beyond the heap data each element might have. - - if T::is_pod() { - 0 // early-out - } else { - self.iter().map(SizeBytes::heap_size_bytes).sum::() - } - } else { - // NOTE: It's all on the heap at this point. - if T::is_pod() { - (self.len() * std::mem::size_of::()) as _ - } else { - self.iter().map(SizeBytes::total_size_bytes).sum::() - } - } - } -} - -impl SizeBytes for Option { - #[inline] - fn heap_size_bytes(&self) -> u64 { - self.as_ref().map_or(0, SizeBytes::heap_size_bytes) - } -} - -impl SizeBytes for Arc { - #[inline] - fn heap_size_bytes(&self) -> u64 { - 0 // assume it's amortized - } -} - -impl SizeBytes for Box { - #[inline] - fn heap_size_bytes(&self) -> u64 { - T::total_size_bytes(&**self) - } -} - -// TODO(rust-lang/rust#31844): `impl SizeBytesExt for T {}` would be nice but -// violates orphan rules. -macro_rules! impl_size_bytes_pod { - ($ty:ty) => { - impl SizeBytes for $ty { - #[inline] - fn heap_size_bytes(&self) -> u64 { - 0 - } - - #[inline] - fn is_pod() -> bool { - true - } - } - }; - ($ty:ty, $($rest:ty),+) => { - impl_size_bytes_pod!($ty); impl_size_bytes_pod!($($rest),+); - }; -} - -impl_size_bytes_pod!(u8, u16, u32, u64, u128, i8, i16, i32, i64, i128, bool, f32, f64); -impl_size_bytes_pod!(half::f16); - -impl SizeBytes for (T, U) -where - T: SizeBytes, - U: SizeBytes, -{ - #[inline] - fn heap_size_bytes(&self) -> u64 { - let (a, b) = self; - a.heap_size_bytes() + b.heap_size_bytes() - } - - #[inline] - fn is_pod() -> bool { - T::is_pod() && U::is_pod() - } -} - -impl SizeBytes for (T, U, V) -where - T: SizeBytes, - U: SizeBytes, - V: SizeBytes, -{ - #[inline] - fn heap_size_bytes(&self) -> u64 { - let (a, b, c) = self; - a.heap_size_bytes() + b.heap_size_bytes() + c.heap_size_bytes() - } - - #[inline] - fn is_pod() -> bool { - T::is_pod() && U::is_pod() && V::is_pod() - } -} - -impl SizeBytes for (T, U, V, W) -where - T: SizeBytes, - U: SizeBytes, - V: SizeBytes, - W: SizeBytes, -{ - #[inline] - fn heap_size_bytes(&self) -> u64 { - let (a, b, c, d) = self; - a.heap_size_bytes() + b.heap_size_bytes() + c.heap_size_bytes() + d.heap_size_bytes() - } - - #[inline] - fn is_pod() -> bool { - T::is_pod() && U::is_pod() && V::is_pod() && W::is_pod() - } -} diff --git a/crates/store/re_types_core/src/tuid.rs b/crates/store/re_types_core/src/tuid.rs index 92f017297e27..c175d56696d2 100644 --- a/crates/store/re_types_core/src/tuid.rs +++ b/crates/store/re_types_core/src/tuid.rs @@ -1,6 +1,5 @@ use std::sync::Arc; -use crate::{DeserializationError, Loggable, SizeBytes}; use arrow2::{ array::{StructArray, UInt64Array}, datatypes::{DataType, Field}, @@ -8,14 +7,9 @@ use arrow2::{ use re_tuid::Tuid; -// --- +use crate::{DeserializationError, Loggable}; -impl SizeBytes for Tuid { - #[inline] - fn heap_size_bytes(&self) -> u64 { - Self::heap_size_bytes(self) - } -} +// --- impl Loggable for Tuid { #[inline] diff --git a/crates/top/re_sdk/Cargo.toml b/crates/top/re_sdk/Cargo.toml index d1855b4d14e9..35f9b2f7cc7a 100644 --- a/crates/top/re_sdk/Cargo.toml +++ b/crates/top/re_sdk/Cargo.toml @@ -50,6 +50,7 @@ web_viewer = [ [dependencies] re_build_info.workspace = true +re_byte_size.workspace = true re_chunk.workspace = true re_log_encoding = { workspace = true, features = ["encoder"] } re_log_types.workspace = true diff --git a/crates/top/re_sdk/src/lib.rs b/crates/top/re_sdk/src/lib.rs index 2ef51e0e1dd7..642e844ae903 100644 --- a/crates/top/re_sdk/src/lib.rs +++ b/crates/top/re_sdk/src/lib.rs @@ -94,9 +94,11 @@ pub use re_types_core::{ Archetype, ArchetypeName, AsComponents, Component, ComponentBatch, ComponentBatchCow, ComponentBatchCowWithDescriptor, ComponentDescriptor, ComponentName, DatatypeName, DeserializationError, DeserializationResult, GenericIndicatorComponent, Loggable, - LoggableBatch, NamedIndicatorComponent, SerializationError, SerializationResult, SizeBytes, + LoggableBatch, NamedIndicatorComponent, SerializationError, SerializationResult, }; +pub use re_byte_size::SizeBytes; + #[cfg(feature = "data_loaders")] pub use re_data_loader::{DataLoader, DataLoaderError, DataLoaderSettings, LoadedData}; diff --git a/crates/top/rerun/Cargo.toml b/crates/top/rerun/Cargo.toml index 7c3aa2e113d7..5b4ee234beb2 100644 --- a/crates/top/rerun/Cargo.toml +++ b/crates/top/rerun/Cargo.toml @@ -124,6 +124,7 @@ web_viewer = ["server", "dep:re_web_viewer_server", "re_sdk?/web_viewer"] [dependencies] re_build_info.workspace = true +re_byte_size.workspace = true re_capabilities.workspace = true re_chunk.workspace = true re_crash_handler.workspace = true diff --git a/crates/top/rerun/src/commands/rrd/print.rs b/crates/top/rerun/src/commands/rrd/print.rs index f5145f62fb20..d0ef673f9058 100644 --- a/crates/top/rerun/src/commands/rrd/print.rs +++ b/crates/top/rerun/src/commands/rrd/print.rs @@ -1,9 +1,9 @@ use anyhow::Context; use itertools::Itertools; +use re_byte_size::SizeBytes as _; use re_log_types::{LogMsg, SetStoreInfo}; use re_sdk::log::Chunk; -use re_types::SizeBytes as _; use crate::commands::read_rrd_streams_from_file_or_stdin; diff --git a/crates/utils/re_byte_size/Cargo.toml b/crates/utils/re_byte_size/Cargo.toml new file mode 100644 index 000000000000..6cf0e1858b4b --- /dev/null +++ b/crates/utils/re_byte_size/Cargo.toml @@ -0,0 +1,31 @@ +[package] +name = "re_byte_size" +authors.workspace = true +description = "Calculate the heap-allocated size of values at runtime." +edition.workspace = true +homepage.workspace = true +include.workspace = true +license.workspace = true +publish = true +readme = "README.md" +repository.workspace = true +rust-version.workspace = true +version.workspace = true + +[lints] +workspace = true + +[package.metadata.docs.rs] +all-features = true + + +[features] + + +[dependencies] +# TODO(emilk): make some of these opt-in +arrow.workspace = true +arrow2.workspace = true +half.workspace = true +smallvec.workspace = true +re_tuid.workspace = true # TODO(emilk): maybe re_tuid should depend on re_byte_size instead? diff --git a/crates/utils/re_byte_size/README.md b/crates/utils/re_byte_size/README.md new file mode 100644 index 000000000000..f162264ac63f --- /dev/null +++ b/crates/utils/re_byte_size/README.md @@ -0,0 +1,10 @@ +# re_byte_size + +Part of the [`rerun`](https://github.com/rerun-io/rerun) family of crates. + +[![Latest version](https://img.shields.io/crates/v/re_byte_size.svg)](https://crates.io/crates/re_byte_size?speculative-link) +[![Documentation](https://docs.rs/re_byte_size/badge.svg)](https://docs.rs/re_byte_size?speculative-link) +![MIT](https://img.shields.io/badge/license-MIT-blue.svg) +![Apache](https://img.shields.io/badge/license-Apache-blue.svg) + +Calculate the heap-allocated size of values at runtime. diff --git a/crates/store/re_types_core/src/size_bytes/arrow2_sizes.rs b/crates/utils/re_byte_size/src/arrow2_sizes.rs similarity index 99% rename from crates/store/re_types_core/src/size_bytes/arrow2_sizes.rs rename to crates/utils/re_byte_size/src/arrow2_sizes.rs index 5a4b5f3a1b15..ddac7760dc41 100644 --- a/crates/store/re_types_core/src/size_bytes/arrow2_sizes.rs +++ b/crates/utils/re_byte_size/src/arrow2_sizes.rs @@ -93,6 +93,8 @@ fn validity_size(validity: Option<&Bitmap>) -> usize { /// /// FFI buffers are included in this estimation. fn estimated_bytes_size(array: &dyn Array) -> usize { + #![allow(clippy::unwrap_used)] // We check the type first + // NOTE: `.len()` is the number of elements in an arrow2 buffer // no matter WHAT the documentation says. // See https://github.com/jorgecarleitao/arrow2/issues/1430 diff --git a/crates/store/re_types_core/src/size_bytes/arrow_sizes.rs b/crates/utils/re_byte_size/src/arrow_sizes.rs similarity index 100% rename from crates/store/re_types_core/src/size_bytes/arrow_sizes.rs rename to crates/utils/re_byte_size/src/arrow_sizes.rs diff --git a/crates/utils/re_byte_size/src/lib.rs b/crates/utils/re_byte_size/src/lib.rs new file mode 100644 index 000000000000..3459d5d21b5b --- /dev/null +++ b/crates/utils/re_byte_size/src/lib.rs @@ -0,0 +1,47 @@ +//! Calculate the heap-allocated size of values at runtime. + +mod arrow2_sizes; +mod arrow_sizes; +mod primitive_sizes; +mod smallvec_sizes; +mod std_sizes; +mod tuple_sizes; + +// --- + +/// Approximations of stack and heap size for both internal and external types. +/// +/// Motly used for statistics and triggering events such as garbage collection. +pub trait SizeBytes { + /// Returns the total size of `self` in bytes, accounting for both stack and heap space. + #[inline] + fn total_size_bytes(&self) -> u64 { + self.stack_size_bytes() + self.heap_size_bytes() + } + + /// Returns the total size of `self` on the stack, in bytes. + /// + /// Defaults to `std::mem::size_of_val(self)`. + #[inline] + fn stack_size_bytes(&self) -> u64 { + std::mem::size_of_val(self) as _ + } + + /// Returns the total size of `self` on the heap, in bytes. + fn heap_size_bytes(&self) -> u64; + + /// Is `Self` just plain old data? + /// + /// If `true`, this will make most blanket implementations of `SizeBytes` much faster (e.g. `Vec`). + #[inline] + fn is_pod() -> bool { + false + } +} + +impl SizeBytes for re_tuid::Tuid { + #[inline] + fn heap_size_bytes(&self) -> u64 { + 0 + } +} diff --git a/crates/utils/re_byte_size/src/primitive_sizes.rs b/crates/utils/re_byte_size/src/primitive_sizes.rs new file mode 100644 index 000000000000..d66b5e5fc57c --- /dev/null +++ b/crates/utils/re_byte_size/src/primitive_sizes.rs @@ -0,0 +1,28 @@ +use crate::SizeBytes; + +// TODO(rust-lang/rust#31844): This isn't happening without specialization. +// impl SizeBytes for T where T: bytemuck::Pod { … } + +// TODO(rust-lang/rust#31844): `impl SizeBytesExt for T {}` would be nice but +// violates orphan rules. +macro_rules! impl_size_bytes_pod { + ($ty:ty) => { + impl SizeBytes for $ty { + #[inline] + fn heap_size_bytes(&self) -> u64 { + 0 + } + + #[inline] + fn is_pod() -> bool { + true + } + } + }; + ($ty:ty, $($rest:ty),+) => { + impl_size_bytes_pod!($ty); impl_size_bytes_pod!($($rest),+); + }; +} + +impl_size_bytes_pod!(u8, u16, u32, u64, u128, i8, i16, i32, i64, i128, bool, f32, f64); +impl_size_bytes_pod!(half::f16); diff --git a/crates/utils/re_byte_size/src/smallvec_sizes.rs b/crates/utils/re_byte_size/src/smallvec_sizes.rs new file mode 100644 index 000000000000..468b52d6457f --- /dev/null +++ b/crates/utils/re_byte_size/src/smallvec_sizes.rs @@ -0,0 +1,27 @@ +use smallvec::SmallVec; + +use crate::SizeBytes; + +impl SizeBytes for SmallVec<[T; N]> { + /// Does not take capacity into account. + #[inline] + fn heap_size_bytes(&self) -> u64 { + if self.len() <= N { + // The `SmallVec` is still smaller than the threshold so no heap data has been + // allocated yet, beyond the heap data each element might have. + + if T::is_pod() { + 0 // early-out + } else { + self.iter().map(SizeBytes::heap_size_bytes).sum::() + } + } else { + // NOTE: It's all on the heap at this point. + if T::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.iter().map(SizeBytes::total_size_bytes).sum::() + } + } + } +} diff --git a/crates/utils/re_byte_size/src/std_sizes.rs b/crates/utils/re_byte_size/src/std_sizes.rs new file mode 100644 index 000000000000..063a2bbfbb6b --- /dev/null +++ b/crates/utils/re_byte_size/src/std_sizes.rs @@ -0,0 +1,132 @@ +//! Implement [`SizeBytes`] for things in the standard library. + +use std::{ + collections::{BTreeMap, BTreeSet, HashMap, VecDeque}, + sync::Arc, +}; + +use crate::SizeBytes; + +impl SizeBytes for String { + /// Does not take capacity into account. + #[inline] + fn heap_size_bytes(&self) -> u64 { + self.as_bytes().len() as u64 + } +} + +impl SizeBytes for BTreeMap { + #[inline] + fn heap_size_bytes(&self) -> u64 { + // NOTE: It's all on the heap at this point. + + let keys_size_bytes = if K::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.keys().map(SizeBytes::total_size_bytes).sum::() + }; + + let values_size_bytes = if V::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.values().map(SizeBytes::total_size_bytes).sum::() + }; + + keys_size_bytes + values_size_bytes + } +} + +impl SizeBytes for BTreeSet { + #[inline] + fn heap_size_bytes(&self) -> u64 { + // NOTE: It's all on the heap at this point. + + if K::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.iter().map(SizeBytes::total_size_bytes).sum::() + } + } +} + +impl SizeBytes for HashMap { + #[inline] + fn heap_size_bytes(&self) -> u64 { + // NOTE: It's all on the heap at this point. + + let keys_size_bytes = if K::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.keys().map(SizeBytes::total_size_bytes).sum::() + }; + + let values_size_bytes = if V::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.values().map(SizeBytes::total_size_bytes).sum::() + }; + + keys_size_bytes + values_size_bytes + } +} + +// NOTE: Do _not_ implement `SizeBytes` for slices: we cannot know whether they point to the stack +// or the heap! + +impl SizeBytes for [T; N] { + #[inline] + fn heap_size_bytes(&self) -> u64 { + if T::is_pod() { + 0 // it's a const-sized array + } else { + self.iter().map(SizeBytes::heap_size_bytes).sum::() + } + } +} + +impl SizeBytes for Vec { + /// Does not take capacity into account. + #[inline] + fn heap_size_bytes(&self) -> u64 { + // NOTE: It's all on the heap at this point. + if T::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.iter().map(SizeBytes::total_size_bytes).sum::() + } + } +} + +impl SizeBytes for VecDeque { + /// Does not take capacity into account. + #[inline] + fn heap_size_bytes(&self) -> u64 { + // NOTE: It's all on the heap at this point. + if T::is_pod() { + (self.len() * std::mem::size_of::()) as _ + } else { + self.iter().map(SizeBytes::total_size_bytes).sum::() + } + } +} + +impl SizeBytes for Option { + #[inline] + fn heap_size_bytes(&self) -> u64 { + self.as_ref().map_or(0, SizeBytes::heap_size_bytes) + } +} + +impl SizeBytes for Arc { + #[inline] + fn heap_size_bytes(&self) -> u64 { + 0 // assume it's amortized + } +} + +impl SizeBytes for Box { + #[inline] + fn heap_size_bytes(&self) -> u64 { + T::total_size_bytes(&**self) + } +} diff --git a/crates/utils/re_byte_size/src/tuple_sizes.rs b/crates/utils/re_byte_size/src/tuple_sizes.rs new file mode 100644 index 000000000000..3476bccfdbc8 --- /dev/null +++ b/crates/utils/re_byte_size/src/tuple_sizes.rs @@ -0,0 +1,55 @@ +use crate::SizeBytes; + +impl SizeBytes for (T, U) +where + T: SizeBytes, + U: SizeBytes, +{ + #[inline] + fn heap_size_bytes(&self) -> u64 { + let (a, b) = self; + a.heap_size_bytes() + b.heap_size_bytes() + } + + #[inline] + fn is_pod() -> bool { + T::is_pod() && U::is_pod() + } +} + +impl SizeBytes for (T, U, V) +where + T: SizeBytes, + U: SizeBytes, + V: SizeBytes, +{ + #[inline] + fn heap_size_bytes(&self) -> u64 { + let (a, b, c) = self; + a.heap_size_bytes() + b.heap_size_bytes() + c.heap_size_bytes() + } + + #[inline] + fn is_pod() -> bool { + T::is_pod() && U::is_pod() && V::is_pod() + } +} + +impl SizeBytes for (T, U, V, W) +where + T: SizeBytes, + U: SizeBytes, + V: SizeBytes, + W: SizeBytes, +{ + #[inline] + fn heap_size_bytes(&self) -> u64 { + let (a, b, c, d) = self; + a.heap_size_bytes() + b.heap_size_bytes() + c.heap_size_bytes() + d.heap_size_bytes() + } + + #[inline] + fn is_pod() -> bool { + T::is_pod() && U::is_pod() && V::is_pod() && W::is_pod() + } +} diff --git a/crates/utils/re_tuid/src/lib.rs b/crates/utils/re_tuid/src/lib.rs index b95d8bd9fec9..5a19ef51df71 100644 --- a/crates/utils/re_tuid/src/lib.rs +++ b/crates/utils/re_tuid/src/lib.rs @@ -24,16 +24,6 @@ impl Tuid { /// as a hack so that we can compactly format them when printing Arrow data to the terminal. /// Check out `re_format_arrow` for context. pub const NAME: &'static str = "rerun.datatypes.TUID"; - - /// Returns the total size of `self` on the heap, in bytes. - /// - /// NOTE: This crate cannot depend on `re_types_core`, therefore the actual implementation of - /// `SizeBytes for Tuid` lives in `re_types_core` and calls this method. - #[inline] - pub fn heap_size_bytes(&self) -> u64 { - let Self { time_ns: _, inc: _ } = self; - 0 - } } impl std::fmt::Display for Tuid { diff --git a/crates/viewer/re_chunk_store_ui/Cargo.toml b/crates/viewer/re_chunk_store_ui/Cargo.toml index 89b5bc61f0ec..36b820ea6e96 100644 --- a/crates/viewer/re_chunk_store_ui/Cargo.toml +++ b/crates/viewer/re_chunk_store_ui/Cargo.toml @@ -19,6 +19,7 @@ workspace = true all-features = true [dependencies] +re_byte_size.workspace = true re_chunk_store.workspace = true re_format.workspace = true re_log_types.workspace = true diff --git a/crates/viewer/re_chunk_store_ui/src/arrow_ui.rs b/crates/viewer/re_chunk_store_ui/src/arrow_ui.rs index f3ee0ef8abd3..ec575ac9fcb1 100644 --- a/crates/viewer/re_chunk_store_ui/src/arrow_ui.rs +++ b/crates/viewer/re_chunk_store_ui/src/arrow_ui.rs @@ -1,8 +1,8 @@ use itertools::Itertools; +use re_byte_size::SizeBytes as _; use re_chunk_store::external::arrow2; use re_chunk_store::external::arrow2::array::Utf8Array; -use re_types::SizeBytes as _; use re_ui::UiExt; // Note: this is copied and heavily modified from `re_data_ui`. We don't want to unify them because diff --git a/crates/viewer/re_chunk_store_ui/src/chunk_ui.rs b/crates/viewer/re_chunk_store_ui/src/chunk_ui.rs index d7283f48a6a5..95172867413a 100644 --- a/crates/viewer/re_chunk_store_ui/src/chunk_ui.rs +++ b/crates/viewer/re_chunk_store_ui/src/chunk_ui.rs @@ -4,9 +4,9 @@ use std::sync::Arc; use egui_extras::{Column, TableRow}; use itertools::Itertools; +use re_byte_size::SizeBytes; use re_chunk_store::external::re_chunk::{Arrow2Array, TransportChunk}; use re_chunk_store::Chunk; -use re_log_types::external::re_types_core::SizeBytes; use re_log_types::{TimeZone, Timeline}; use re_types::datatypes::TimeInt; use re_ui::{list_item, UiExt}; diff --git a/crates/viewer/re_component_ui/Cargo.toml b/crates/viewer/re_component_ui/Cargo.toml index 42db39072dab..3bf6e52532fe 100644 --- a/crates/viewer/re_component_ui/Cargo.toml +++ b/crates/viewer/re_component_ui/Cargo.toml @@ -19,8 +19,9 @@ workspace = true all-features = true [dependencies] -re_data_ui.workspace = true # Needed for `item_ui`. +re_byte_size.workspace = true re_data_source.workspace = true +re_data_ui.workspace = true # Needed for `item_ui`. re_format.workspace = true re_log.workspace = true re_log_types.workspace = true diff --git a/crates/viewer/re_component_ui/src/fallback_ui.rs b/crates/viewer/re_component_ui/src/fallback_ui.rs index 73ddab380bea..31b6c27ff1bd 100644 --- a/crates/viewer/re_component_ui/src/fallback_ui.rs +++ b/crates/viewer/re_component_ui/src/fallback_ui.rs @@ -31,7 +31,7 @@ fn arrow_ui(ui: &mut egui::Ui, ui_layout: UiLayout, array: &dyn arrow::array::Ar } fn arrow2_ui(ui: &mut egui::Ui, ui_layout: UiLayout, array: &dyn arrow2::array::Array) { - use re_types::SizeBytes as _; + use re_byte_size::SizeBytes as _; // Special-treat text. // Note: we match on the raw data here, so this works for any component containing text. diff --git a/crates/viewer/re_data_ui/Cargo.toml b/crates/viewer/re_data_ui/Cargo.toml index 5cec64d98580..0ffb3549fc3c 100644 --- a/crates/viewer/re_data_ui/Cargo.toml +++ b/crates/viewer/re_data_ui/Cargo.toml @@ -19,6 +19,7 @@ workspace = true all-features = true [dependencies] +re_byte_size.workspace = true re_capabilities = { workspace = true, features = ["egui"] } re_chunk_store.workspace = true re_entity_db.workspace = true diff --git a/crates/viewer/re_data_ui/src/entity_db.rs b/crates/viewer/re_data_ui/src/entity_db.rs index 5d2a5e33fe52..ffa031e62744 100644 --- a/crates/viewer/re_data_ui/src/entity_db.rs +++ b/crates/viewer/re_data_ui/src/entity_db.rs @@ -1,7 +1,7 @@ +use re_byte_size::SizeBytes; use re_chunk_store::ChunkStoreConfig; use re_entity_db::EntityDb; use re_log_types::StoreKind; -use re_types::SizeBytes; use re_ui::UiExt as _; use re_viewer_context::{UiLayout, ViewerContext}; diff --git a/crates/viewer/re_data_ui/src/item_ui.rs b/crates/viewer/re_data_ui/src/item_ui.rs index 6526276ab9ec..1005e60fb5ae 100644 --- a/crates/viewer/re_data_ui/src/item_ui.rs +++ b/crates/viewer/re_data_ui/src/item_ui.rs @@ -732,7 +732,7 @@ pub fn entity_db_button_ui( entity_db: &re_entity_db::EntityDb, include_app_id: bool, ) { - use re_types_core::SizeBytes as _; + use re_byte_size::SizeBytes as _; use re_viewer_context::{SystemCommand, SystemCommandSender as _}; let app_id_prefix = if include_app_id { diff --git a/crates/viewer/re_ui/src/arrow_ui.rs b/crates/viewer/re_ui/src/arrow_ui.rs new file mode 100644 index 000000000000..10398d6e771b --- /dev/null +++ b/crates/viewer/re_ui/src/arrow_ui.rs @@ -0,0 +1,79 @@ +use itertools::Itertools as _; + +use crate::UiExt as _; +use re_byte_size::SizeBytes as _; + +use arrow2::array::Utf8Array; + +pub(crate) fn arrow_ui(ui: &mut egui::Ui, array: &dyn arrow2::array::Array) { + ui.scope(|ui| { + ui.style_mut().wrap_mode = Some(egui::TextWrapMode::Truncate); + + // Special-treat text. + // Note: we match on the raw data here, so this works for any component containing text. + if let Some(utf8) = array.as_any().downcast_ref::>() { + if utf8.len() == 1 { + let string = utf8.value(0); + ui.monospace(string); + return; + } + } + if let Some(utf8) = array.as_any().downcast_ref::>() { + if utf8.len() == 1 { + let string = utf8.value(0); + ui.monospace(string); + return; + } + } + + let num_bytes = array.total_size_bytes(); + if num_bytes < 3000 { + if array.is_empty() { + ui.monospace("[]"); + return; + } + + let instance_count = array.len(); + let display = arrow2::array::get_display(array, "null"); + + if instance_count == 1 { + let mut string = String::new(); + match display(&mut string, 0) { + Ok(_) => ui.monospace(&string), + Err(err) => ui.error_with_details_on_hover(err.to_string()), + }; + return; + } else { + ui.label(format!("{instance_count} items")) + .on_hover_ui(|ui| { + ui.style_mut().wrap_mode = Some(egui::TextWrapMode::Wrap); + ui.monospace(format!( + "[{}]", + (0..instance_count) + .filter_map(|index| { + let mut s = String::new(); + //TODO(ab): should we care about errors here? + display(&mut s, index).ok().map(|_| s) + }) + .join(", ") + )); + }); + } + + return; + } + + // Fallback: + let bytes = re_format::format_bytes(num_bytes as _); + + let data_type_formatted = format!("{:?}", array.data_type()); + + if data_type_formatted.len() < 20 { + // e.g. "4.2 KiB of Float32" + ui.label(format!("{bytes} of {data_type_formatted}")); + } else { + // Huge datatype, probably a union horror show + ui.label(format!("{bytes} of data")); + } + }); +} diff --git a/examples/rust/extend_viewer_ui/src/main.rs b/examples/rust/extend_viewer_ui/src/main.rs index 7c8cb9918133..dbd3d8ece57c 100644 --- a/examples/rust/extend_viewer_ui/src/main.rs +++ b/examples/rust/extend_viewer_ui/src/main.rs @@ -1,7 +1,8 @@ //! This example shows how to wrap the Rerun Viewer in your own GUI. use re_viewer::external::{ - arrow2, eframe, egui, re_chunk_store, re_entity_db, re_log, re_log_types, re_memory, re_types, + arrow2, eframe, egui, re_byte_size, re_chunk_store, re_entity_db, re_log, re_log_types, + re_memory, re_types, }; // By using `re_memory::AccountingAllocator` Rerun can keep track of exactly how much memory it is using, @@ -178,7 +179,7 @@ fn component_ui( } fn format_arrow2(value: &dyn arrow2::array::Array) -> String { - use re_types::SizeBytes as _; + use re_byte_size::SizeBytes as _; let bytes = value.total_size_bytes(); if bytes < 256 {