facultyai / marshmallow-dataframe Goto Github PK
View Code? Open in Web Editor NEWMarshmallow Schema generator for Pandas DataFrames
Home Page: https://pypi.org/project/marshmallow-dataframe/
License: Apache License 2.0
Marshmallow Schema generator for Pandas DataFrames
Home Page: https://pypi.org/project/marshmallow-dataframe/
License: Apache License 2.0
Hello, thank you very much for your project, I've been looking for a more practical way to do a schema treatment with pandas.
I would like some help, in my project, separated schema into a module and instantiate, for example, the class DataSchema (SplitDataFrameSchema)
. But she dont recognize Meta parameter, dtype, how can I dynamically assign it (based on the input data)?
My structure in Tree:
├── app
│ ├── api.py
│ ├── __init__.py
│ ├── db
│ │ ├── core.py
│ │ ├── __init__.py
│ ├── resources
│ │ ├── analysis_data.py
│ │ ├── __init__.py
│ ├── schemas.py
│ └── utils.py
├── config.py
├── connections.log
└── main.py
My Schema code:
from marshmallow_dataframe import SplitDataFrameSchema
class DataSchema(SplitDataFrameSchema):
"""Automatically generated schema for dataframe"""
class Meta:
dtypes = self.dtypes
Hi, and thanks for the work on this package !
I am also trying to get that working nicely together...
I recently encountered :
{'index': ['Missing data for required field.']}
But I expected index to be optional (when not present assume range(n), same as pandas.DataFrame()
What do you think ?
Right now categorical columns are always recognised as a string dtype, which could be wrong. In addition, we are not validating that the deserialised values are one of the category options.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.