@@ -698,6 +698,16 @@ impl PyGrid {
698
698
. collect ( )
699
699
}
700
700
701
+ /// Rotate the Grid into the specified basis
702
+ ///
703
+ /// Parameters
704
+ /// ----------
705
+ /// pid_basis: PyPidBasis
706
+ /// PID basis of the resulting Grid
707
+ pub fn rotate_pid_basis ( & mut self , pid_basis : PyPidBasis ) {
708
+ self . grid . rotate_pid_basis ( pid_basis. into ( ) ) ;
709
+ }
710
+
701
711
/// Scale all subgrids.
702
712
///
703
713
/// Parameters
@@ -716,12 +726,23 @@ impl PyGrid {
716
726
///
717
727
/// Parameters
718
728
/// ----------
719
- /// factors : numpy.ndarray [float]
729
+ /// factors : list [float]
720
730
/// bin-dependent factors by which to scale
721
731
pub fn scale_by_bin ( & mut self , factors : Vec < f64 > ) {
722
732
self . grid . scale_by_bin ( & factors) ;
723
733
}
724
734
735
+ /// Delete orders with the corresponding `order_indices`. Repeated indices and indices larger
736
+ /// or equal than the number of orders are ignored.
737
+ ///
738
+ /// Parameters
739
+ /// ----------
740
+ /// order_indices : list[int]
741
+ /// list of indices of orders to be removed
742
+ pub fn delete_orders ( & mut self , order_indices : Vec < usize > ) {
743
+ self . grid . delete_orders ( & order_indices) ;
744
+ }
745
+
725
746
/// Delete bins.
726
747
///
727
748
/// # Panics
@@ -732,11 +753,27 @@ impl PyGrid {
732
753
///
733
754
/// Parameters
734
755
/// ----------
735
- /// bin_indices : numpy.ndarray [int]
736
- /// list of indices of bins to removed
756
+ /// bin_indices : list [int]
757
+ /// list of indices of bins to be removed
737
758
pub fn delete_bins ( & mut self , bin_indices : Vec < usize > ) {
738
759
self . grid . delete_bins ( & bin_indices) ;
739
760
}
761
+
762
+ /// Deletes channels with the corresponding `channel_indices`. Repeated indices and indices
763
+ /// larger or equal than the number of channels are ignored.
764
+ ///
765
+ /// Parameters
766
+ /// ----------
767
+ /// bin_indices : list[int]
768
+ /// list of indices of bins to be removed
769
+ pub fn delete_channels ( & mut self , channel_indices : Vec < usize > ) {
770
+ self . grid . delete_channels ( & channel_indices) ;
771
+ }
772
+
773
+ /// Splits the grid such that each channel contains only a single tuple of PIDs.
774
+ pub fn split_channels ( & mut self ) {
775
+ self . grid . split_channels ( ) ;
776
+ }
740
777
}
741
778
742
779
/// Register submodule in parent.
0 commit comments