-
Notifications
You must be signed in to change notification settings - Fork 20
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
Writing models with such objects as DataFrames as refs or as Cells values #15
Comments
Are you referring to no-arg cells with simple values like the attached? |
I'm looking for no-arg cells with pandas (DataFrame/Series) content. The same as |
You can assign your pandas object to a ref, and refer to the ref from your cells. That's the only way available now. I'm working on dependency tracking on refs as well. Once it's available then you don't have much incentive to store constants in cells. |
I actually like the concept of storing all the data in cells regardless if these are cells with or without args. Why would to prohibit storing data in cells without args? |
I'm not prohibiting storing data in cells without args. The bottom line is, currently it not possible to store values of arbitrary cells with |
Thanks. At the moment I'm storing data in the cells without args using low level calls: |
Not sure I'm following you. You want to do something like below correct?
|
I'm not using |
(correction) The comment below was for #13 , posted here by mistake. v0.0.25 is released and the stack tracing feature is introduced. See https://modelx.readthedocs.io/en/latest/releases/relnotes_v0_0_25.html |
The new version is awesome!!! It allows me to fully track the number of calls to the function and the time it takes to evaluate each call. Thank you very much! |
Sorry, I misunderstood you earlier: I thought the approach described above works. It seems that even single value stored in the cell without arguments can't be restored:
It would be really helpful to have this functionality including pandas objects. I won't be able to use |
I've also noticed that it isn't possible to have DataFrame as a ref. Is it intentional this way? |
You can have DFs as refs. You mean you can't |
Using your earlier example:
|
Another thing is that the following code, which works with
There is an easy workaround for this one, hence not important. |
modelx version 0.1.0 is released, and input values of a cells are distinguished from calculated values, and they are saved by |
I need to create a cell with no arguments and some data inside. Is there a way to do it so that "write_model" will capture it?
The text was updated successfully, but these errors were encountered: