Take the last `n` rows of every partition Typically used after `Partitions(..., [-1])` to take the last `n` rows of an entire collection.
| 2712 | |
| 2713 | |
| 2714 | class BlockwiseTail(Tail, Blockwise): |
| 2715 | """Take the last `n` rows of every partition |
| 2716 | |
| 2717 | Typically used after `Partitions(..., [-1])` to take |
| 2718 | the last `n` rows of an entire collection. |
| 2719 | """ |
| 2720 | |
| 2721 | _preserves_partitioning_information = True |
| 2722 | |
| 2723 | def _divisions(self): |
| 2724 | return self.frame.divisions |
| 2725 | |
| 2726 | def _task(self, name: Key, index: int) -> Task: |
| 2727 | return Task(name, M.tail, TaskRef((self.frame._name, index)), self.n) |
| 2728 | |
| 2729 | |
| 2730 | class BlockwiseTailIndex(BlockwiseTail): |