Binary columns rendered as boolean values
tr31zh opened this issue · comments
System Information
- OS: MacOS 12.5.1
- Python version: 3.10.6
- Python environment: pip
- Using jupyter: true
- Datapane version: 0.15.0
Bug / Issue
When using dataframes, binary columns are rendrered as boolean values
ex:
dp.DataTable( pd.DataFrame( { 1: [1, 0, 0, 1], 2: [1, 0, 0, 1], 3: [1, 0, 0, 1], 4: [1, 0, 0, 1], 5: [1, 0, 0, 1], 6: [1, 0, 0, 1], } ) )
Will be rendered as:
1 2 ...
True True ...
False False. ...
@shahinrostami agreed, yes let's disable this optimisation and do a patch release. I assume the integer optimisation will kick in anyway and it will store these as uint8
anyway which is still a size saving
Just a heartbeat to confirm that I'll be picking this one up today 👍
Pending a review, this fix should make it into our release! I'll label this issue as release pending
for now.
Re-opening until the fix makes it into a release
Hey @tr31zh - this should have been fixed in the recent release! I've confirmed it with the example:
import datapane as dp
import pandas as pd
app = dp.App(
dp.DataTable(
pd.DataFrame(
{
1: [1, 0, 0, 1],
2: [1, 0, 0, 1],
3: [1, 0, 0, 1],
4: [1, 0, 0, 1],
5: [1, 0, 0, 1],
6: [1, 0, 0, 1],
}
)
)
).save("test.html")
Thank you for raising this – please let us know if there's anything else!
Hi @shahinrostami ,
I've just checked, everything looks fine.
Thank you!
Hi @shahinrostami ,
I've just checked, everything looks fine.
Thank you!
Perfect, happy to hear it!