-
Notifications
You must be signed in to change notification settings - Fork 175
Unify X and layers #1707
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
base: main
Are you sure you want to change the base?
Unify X and layers #1707
Conversation
❌ 156 Tests Failed:
View the top 3 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
So re: the backed question, I think the answer is not to get rid of it, but to clarify its behavior. To do that, I think we should merge #1927 first, which may include a breaking change. If we stop allowing overriding of on-disk stores (which currently relies on inheritance form scipy.sparse private methods), then this question becomes much more simplified. The next step after #1927 would probably be to simplify it. From what I can tell, the reaosn we need to track if the file is open or not is because if writing. If everything were purely read-only, I think it would be less of an issue. My vision there would be in "backed" mode (after the two above points are implemented), we would simply take the |
|
||
@X.setter | ||
def X(self, value: XDataType | None): # noqa: PLR0912 | ||
if value is None: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think a lot of this deleted logic contains things that layers
can't currently do. For example, overriding the backing X
; currently, if you try to override a part of a view of a layers, it will just actualize and not override the old data. But if you do adata_view.X = 1
it will fill ones in to the parent AnnData
object. I'm not sure what the history is there, but it accounts for a pretty big discrepancy in functionality
Co-authored-by: Philipp A. <[email protected]>
X
areNone
#678TODO:
dtype
arg: just remove? or ignore+warning? (unless we already do that, then remove)X
areNone
#678