From 175f48713ce3638b98d780b9be9eed745f079fac Mon Sep 17 00:00:00 2001 From: Clement Rey Date: Thu, 20 Jul 2023 10:57:18 +0200 Subject: [PATCH] codegen --- crates/re_types/source_hash.txt | 2 +- crates/re_types/src/components/fuzzy.rs | 1849 +---------------- crates/re_types/src/components/transform3d.rs | 178 +- crates/re_types/src/datatypes/fuzzy.rs | 1233 +---------- crates/re_types/src/datatypes/rotation3d.rs | 56 +- .../src/datatypes/rotation_axis_angle.rs | 35 +- crates/re_types/src/datatypes/scale3d.rs | 10 +- crates/re_types/src/datatypes/transform3d.rs | 178 +- .../src/datatypes/translation_and_mat3x3.rs | 20 +- .../datatypes/translation_rotation_scale3d.rs | 120 +- 10 files changed, 71 insertions(+), 3610 deletions(-) diff --git a/crates/re_types/source_hash.txt b/crates/re_types/source_hash.txt index af06973b81b7..fe3754492283 100644 --- a/crates/re_types/source_hash.txt +++ b/crates/re_types/source_hash.txt @@ -1,4 +1,4 @@ # This is a sha256 hash for all direct and indirect dependencies of this crate's build script. # It can be safely removed at anytime to force the build script to run again. # Check out build.rs to see how it's computed. -e11a5960ff29c75374e3298ae9f2728d9d6d838c517e1b1ee3bc2a18fada0efb +4e2dbe4d7ae1aec1009d44834ae84119ba1f1451ae63b1cf5ebd25f2e6224170 diff --git a/crates/re_types/src/components/fuzzy.rs b/crates/re_types/src/components/fuzzy.rs index 97c5fde3caaf..8186f5d9563f 100644 --- a/crates/re_types/src/components/fuzzy.rs +++ b/crates/re_types/src/components/fuzzy.rs @@ -102,12 +102,7 @@ impl crate::Loggable for AffixFuzzer1 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -276,12 +271,7 @@ impl crate::Loggable for AffixFuzzer2 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -452,12 +442,7 @@ impl crate::Loggable for AffixFuzzer3 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -628,12 +613,7 @@ impl crate::Loggable for AffixFuzzer4 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -800,12 +780,7 @@ impl crate::Loggable for AffixFuzzer5 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -974,12 +949,7 @@ impl crate::Loggable for AffixFuzzer6 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -1090,82 +1060,7 @@ impl crate::Loggable for AffixFuzzer7 { use ::arrow2::datatypes::*; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), })) @@ -1223,82 +1118,7 @@ impl crate::Loggable for AffixFuzzer7 { "rerun.testing.components.AffixFuzzer7".to_owned(), Box::new(DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }))), @@ -2469,82 +2289,7 @@ impl crate::Loggable for AffixFuzzer14 { name: "craziness".to_owned(), data_type: DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })), @@ -2701,82 +2446,7 @@ impl crate::Loggable for AffixFuzzer15 { name: "craziness".to_owned(), data_type: DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })), @@ -2909,130 +2579,7 @@ impl crate::Loggable for AffixFuzzer16 { use ::arrow2::datatypes::*; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })) @@ -3090,136 +2637,7 @@ impl crate::Loggable for AffixFuzzer16 { "rerun.testing.components.AffixFuzzer16".to_owned(), Box::new(DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - )), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - )), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - )), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }))), @@ -3356,130 +2774,7 @@ impl crate::Loggable for AffixFuzzer17 { use ::arrow2::datatypes::*; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), })) @@ -3539,136 +2834,7 @@ impl crate::Loggable for AffixFuzzer17 { "rerun.testing.components.AffixFuzzer17".to_owned(), Box::new(DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - )), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - )), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new( - Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - )), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }))), @@ -3801,415 +2967,7 @@ impl crate::Loggable for AffixFuzzer18 { use ::arrow2::datatypes::*; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_required".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), })) @@ -4262,145 +3020,34 @@ impl crate::Loggable for AffixFuzzer18 { ) .unwrap() .into(); - ListArray :: new ({ _ = extension_wrapper ; DataType :: Extension ("rerun.testing.components.AffixFuzzer18" . to_owned () , Box :: new (DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Union (vec ! [Field { name : "_null_markers" . to_owned () , data_type : DataType :: Null , is_nullable : true , metadata : [] . into () , } - - , Field { name : "single_required" . to_owned () , data_type : DataType :: Union (vec ! [Field { name : "_null_markers" . to_owned () , data_type : DataType :: Null , is_nullable : true , metadata : [] . into () , } - - , Field { name : "degrees" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "radians" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "craziness" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "single_float_optional" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "single_string_required" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "single_string_optional" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_floats_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_strings_required" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "many_strings_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "flattened_scalar" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "almost_flattened_scalar" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "value" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "from_parent" . to_owned () , data_type : DataType :: Boolean , is_nullable : true , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "fixed_size_shenanigans" . to_owned () , data_type : DataType :: FixedSizeList (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - -) , 3usize) , is_nullable : false , metadata : [] . into () , } - - ,] , Some (vec ! [0i32 , 1i32 , 2i32 , 3i32 , 4i32 ,]) , UnionMode :: Dense) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "many_required" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Union (vec ! [Field { name : "_null_markers" . to_owned () , data_type : DataType :: Null , is_nullable : true , metadata : [] . into () , } - - , Field { name : "degrees" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "radians" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "craziness" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "single_float_optional" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "single_string_required" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "single_string_optional" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_floats_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_strings_required" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "many_strings_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "flattened_scalar" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "almost_flattened_scalar" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "value" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "from_parent" . to_owned () , data_type : DataType :: Boolean , is_nullable : true , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "fixed_size_shenanigans" . to_owned () , data_type : DataType :: FixedSizeList (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - -) , 3usize) , is_nullable : false , metadata : [] . into () , } - - ,] , Some (vec ! [0i32 , 1i32 , 2i32 , 3i32 , 4i32 ,]) , UnionMode :: Dense) , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "many_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Union (vec ! [Field { name : "_null_markers" . to_owned () , data_type : DataType :: Null , is_nullable : true , metadata : [] . into () , } - - , Field { name : "degrees" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "radians" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "craziness" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "single_float_optional" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "single_string_required" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "single_string_optional" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_floats_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "many_strings_required" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "many_strings_optional" . to_owned () , data_type : DataType :: List (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Utf8 , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : true , metadata : [] . into () , } - - , Field { name : "flattened_scalar" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - , Field { name : "almost_flattened_scalar" . to_owned () , data_type : DataType :: Struct (vec ! [Field { name : "value" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "from_parent" . to_owned () , data_type : DataType :: Boolean , is_nullable : true , metadata : [] . into () , } - - ,]) , is_nullable : false , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - , Field { name : "fixed_size_shenanigans" . to_owned () , data_type : DataType :: FixedSizeList (Box :: new (Field { name : "item" . to_owned () , data_type : DataType :: Float32 , is_nullable : false , metadata : [] . into () , } - -) , 3usize) , is_nullable : false , metadata : [] . into () , } - - ,] , Some (vec ! [0i32 , 1i32 , 2i32 , 3i32 , 4i32 ,]) , UnionMode :: Dense) , is_nullable : true , metadata : [] . into () , } - -)) , is_nullable : false , metadata : [] . into () , } - - ,] , Some (vec ! [0i32 , 1i32 , 2i32 , 3i32 ,]) , UnionMode :: Dense) , is_nullable : true , metadata : [] . into () , } - -))) , None) . to_logical_type () . clone () } - - , offsets , { _ = many_optional_unions_inner_bitmap ; _ = extension_wrapper ; crate :: datatypes :: AffixFuzzer4 :: try_to_arrow_opt (many_optional_unions_inner_data , Some ("rerun.testing.components.AffixFuzzer18")) ? } - - , many_optional_unions_bitmap ,) . boxed () + ListArray::new( + { + _ = extension_wrapper; + DataType::Extension( + "rerun.testing.components.AffixFuzzer18".to_owned(), + Box::new(DataType::List(Box::new(Field { + name: "item".to_owned(), + data_type: ::to_arrow_datatype(), + is_nullable: true, + metadata: [].into(), + }))), + None, + ) + .to_logical_type() + .clone() + }, + offsets, + { + _ = many_optional_unions_inner_bitmap; + _ = extension_wrapper; + crate::datatypes::AffixFuzzer4::try_to_arrow_opt( + many_optional_unions_inner_data, + Some("rerun.testing.components.AffixFuzzer18"), + )? + }, + many_optional_unions_bitmap, + ) + .boxed() } }) } @@ -4513,415 +3160,7 @@ impl crate::Loggable for AffixFuzzer19 { use ::arrow2::datatypes::*; DataType::Struct(vec![Field { name: "single_optional_union".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_required".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }]) diff --git a/crates/re_types/src/components/transform3d.rs b/crates/re_types/src/components/transform3d.rs index 0a01b221e049..c7d4fde1f782 100644 --- a/crates/re_types/src/components/transform3d.rs +++ b/crates/re_types/src/components/transform3d.rs @@ -54,187 +54,13 @@ impl crate::Loggable for Transform3D { }, Field { name: "TranslationAndMat3x3".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "matrix".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 9usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: false, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, Field { name: "TranslationRotationScale".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "rotation".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Quaternion".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 4usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "AxisAngle".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "axis".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "angle".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "scale".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "ThreeD".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Uniform".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: false, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/fuzzy.rs b/crates/re_types/src/datatypes/fuzzy.rs index f58e36748116..b16432258c6a 100644 --- a/crates/re_types/src/datatypes/fuzzy.rs +++ b/crates/re_types/src/datatypes/fuzzy.rs @@ -287,12 +287,7 @@ impl crate::Loggable for AffixFuzzer1 { }, Field { name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -1156,82 +1151,7 @@ impl crate::Loggable for AffixFuzzer3 { name: "craziness".to_owned(), data_type: DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })), @@ -1397,82 +1317,8 @@ impl crate::Loggable for AffixFuzzer3 { _ = extension_wrapper; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), + data_type: + ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })) @@ -1769,130 +1615,7 @@ impl crate::Loggable for AffixFuzzer4 { }, Field { name: "single_required".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, @@ -1900,130 +1623,7 @@ impl crate::Loggable for AffixFuzzer4 { name: "many_required".to_owned(), data_type: DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })), @@ -2034,130 +1634,7 @@ impl crate::Loggable for AffixFuzzer4 { name: "many_optional".to_owned(), data_type: DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), })), @@ -2278,147 +1755,8 @@ impl crate::Loggable for AffixFuzzer4 { _ = extension_wrapper; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional" - .to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required" - .to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional" - .to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: - DataType::Float32, - is_nullable: true, - metadata: [].into(), - }), - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }), - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }), - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar" - .to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "value".to_owned(), - data_type: - DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: + ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), })) @@ -2480,147 +1818,8 @@ impl crate::Loggable for AffixFuzzer4 { _ = extension_wrapper; DataType::List(Box::new(Field { name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional" - .to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required" - .to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional" - .to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: - DataType::Float32, - is_nullable: true, - metadata: [].into(), - }), - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }), - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional" - .to_owned(), - data_type: DataType::List( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }), - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar" - .to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "value".to_owned(), - data_type: - DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), + data_type: + ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), })) @@ -2824,415 +2023,7 @@ impl crate::Loggable for AffixFuzzer5 { use ::arrow2::datatypes::*; DataType::Struct(vec![Field { name: "single_optional_union".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_required".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "craziness".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "single_float_optional".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "single_string_required".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "single_string_optional".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_floats_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "many_strings_required".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "many_strings_optional".to_owned(), - data_type: DataType::List(Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Utf8, - is_nullable: true, - metadata: [].into(), - })), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "flattened_scalar".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "almost_flattened_scalar".to_owned(), - data_type: DataType::Struct(vec![Field { - name: "value".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }]), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: true, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "fixed_size_shenanigans".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32, 4i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - })), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32, 3i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }]) diff --git a/crates/re_types/src/datatypes/rotation3d.rs b/crates/re_types/src/datatypes/rotation3d.rs index 881d06d0af2f..8debaf33fb89 100644 --- a/crates/re_types/src/datatypes/rotation3d.rs +++ b/crates/re_types/src/datatypes/rotation3d.rs @@ -57,65 +57,13 @@ impl crate::Loggable for Rotation3D { }, Field { name: "Quaternion".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 4usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, Field { name: "AxisAngle".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "axis".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "angle".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/rotation_axis_angle.rs b/crates/re_types/src/datatypes/rotation_axis_angle.rs index 0ede87fc2cb7..eec8e412ac4f 100644 --- a/crates/re_types/src/datatypes/rotation_axis_angle.rs +++ b/crates/re_types/src/datatypes/rotation_axis_angle.rs @@ -54,44 +54,13 @@ impl crate::Loggable for RotationAxisAngle { DataType::Struct(vec![ Field { name: "axis".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, Field { name: "angle".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/scale3d.rs b/crates/re_types/src/datatypes/scale3d.rs index 3695640af5cb..2017cd2161ce 100644 --- a/crates/re_types/src/datatypes/scale3d.rs +++ b/crates/re_types/src/datatypes/scale3d.rs @@ -57,15 +57,7 @@ impl crate::Loggable for Scale3D { }, Field { name: "ThreeD".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/transform3d.rs b/crates/re_types/src/datatypes/transform3d.rs index 4abf9bd8815a..a00ea0fa3746 100644 --- a/crates/re_types/src/datatypes/transform3d.rs +++ b/crates/re_types/src/datatypes/transform3d.rs @@ -57,187 +57,13 @@ impl crate::Loggable for Transform3D { }, Field { name: "TranslationAndMat3x3".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "matrix".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 9usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: false, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, Field { name: "TranslationRotationScale".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "rotation".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Quaternion".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 4usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "AxisAngle".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "axis".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "angle".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "scale".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "ThreeD".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Uniform".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "from_parent".to_owned(), - data_type: DataType::Boolean, - is_nullable: false, - metadata: [].into(), - }, - ]), + data_type: ::to_arrow_datatype(), is_nullable: false, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/translation_and_mat3x3.rs b/crates/re_types/src/datatypes/translation_and_mat3x3.rs index 8de72fe2fe0f..696e7d4437bf 100644 --- a/crates/re_types/src/datatypes/translation_and_mat3x3.rs +++ b/crates/re_types/src/datatypes/translation_and_mat3x3.rs @@ -56,29 +56,13 @@ impl crate::Loggable for TranslationAndMat3x3 { DataType::Struct(vec![ Field { name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }, Field { name: "matrix".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 9usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }, diff --git a/crates/re_types/src/datatypes/translation_rotation_scale3d.rs b/crates/re_types/src/datatypes/translation_rotation_scale3d.rs index 5d1310583b07..ed7e4230b05a 100644 --- a/crates/re_types/src/datatypes/translation_rotation_scale3d.rs +++ b/crates/re_types/src/datatypes/translation_rotation_scale3d.rs @@ -59,133 +59,19 @@ impl crate::Loggable for TranslationRotationScale3D { DataType::Struct(vec![ Field { name: "translation".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }, Field { name: "rotation".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Quaternion".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 4usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "AxisAngle".to_owned(), - data_type: DataType::Struct(vec![ - Field { - name: "axis".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "angle".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "Radians".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Degrees".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), - is_nullable: false, - metadata: [].into(), - }, - ]), - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), }, Field { name: "scale".to_owned(), - data_type: DataType::Union( - vec![ - Field { - name: "_null_markers".to_owned(), - data_type: DataType::Null, - is_nullable: true, - metadata: [].into(), - }, - Field { - name: "ThreeD".to_owned(), - data_type: DataType::FixedSizeList( - Box::new(Field { - name: "item".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }), - 3usize, - ), - is_nullable: false, - metadata: [].into(), - }, - Field { - name: "Uniform".to_owned(), - data_type: DataType::Float32, - is_nullable: false, - metadata: [].into(), - }, - ], - Some(vec![0i32, 1i32, 2i32]), - UnionMode::Dense, - ), + data_type: ::to_arrow_datatype(), is_nullable: true, metadata: [].into(), },