8000 PERF: implement get_slice in cython by jbrockmendel · Pull Request #41045 · pandas-dev/pandas · GitHub
[go: up one dir, main page]

Skip to content

PERF: implement get_slice in cython #41045

New issue

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

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

Already on GitHub? Sign in to your account

Merged
merged 19 commits into from
Apr 19, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch 'master' into cy-mgr-3
  • Loading branch information
jbrockmendel committed Apr 9, 2021
commit a10825883516662795838dce7ac153c322e309a0
12 changes: 6 additions & 6 deletions pandas/core/internals/managers.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@

# TODO: flexible with index=None and/or items=None

T = TypeVar("T", bound="_BlockManager")
T = TypeVar("T", bound="BaseBlockManager")


class _BlockManager(DataManager):
class BaseBlockManager(DataManager):
"""
Core internal data structure to implement DataFrame, Series, etc.

Expand Down Expand Up @@ -150,7 +150,7 @@ def __init__(self, blocks, axes, verify_integrity=True):
raise NotImplementedError

@classmethod
def from_blocks(cls: type[T], blocks: list[Block], axes: list[Index]) -> T:
def from_blocks(cls: type_t[T], blocks: list[Block], axes: list[Index]) -> T:
raise NotImplementedError

@property
Expand Down Expand Up @@ -1327,9 +1327,9 @@ def take(self: T, indexer, axis: int = 1, verify: bool = True) -> T:
)


class BlockManager(libinternals.BlockManager, _BlockManager):
class BlockManager(libinternals.BlockManager, BaseBlockManager):
"""
_BlockManager that holds 2D blocks.
BaseBlockManager that holds 2D blocks.
"""

ndim = 2
Expand Down Expand Up @@ -1476,7 +1476,7 @@ def unstack(self, unstacker, fill_value) -> BlockManager:
return bm


class SingleBlockManager(_BlockManager, SingleDataManager):
class SingleBlockManager(BaseBlockManager, SingleDataManager):
""" manage a single block with """

ndim = 1
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.
0