How to use the pandera.check_input function in pandera

To help you get started, we’ve selected a few pandera examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pandera-dev / pandera / tests / test_decorators.py View on Github external
    @check_input(DataFrameSchema({"column1": Column(Int)}))
    @check_output(DataFrameSchema({"column2": Column(Float)}))
    def test_func(df):
        return df
github pandera-dev / pandera / tests / test_decorators.py View on Github external
        @check_input(in_schema, 0)
        @check_output(out_schema)
        def transform_first_arg_with_list_getter(self, df):
            return _transform_helper(df)
github pandera-dev / pandera / tests / test_pandera.py View on Github external
        @check_input(in_schema, 0)
        @check_output(out_schema)
        def transform_first_arg_with_list_getter(self, df):
            return _transform_helper(df)
github pandera-dev / pandera / tests / test_decorators.py View on Github external
    @check_input(in_schema, 1)
    @check_output(out_schema, 1)
    def func_input_transform2(_, df):
        return _, df
github pandera-dev / pandera / tests / test_decorators.py View on Github external
    @check_input(in_schema, "in_dataframe")
    @check_output(out_schema, "out_dataframe")
    def test_func3(x, in_dataframe=None):
        return {
            "x": x,
            "out_dataframe": in_dataframe.assign(f=["a", "b", "a"]),
        }
github pandera-dev / pandera / tests / test_decorators.py View on Github external
    @check_input(in_schema)
    @check_output(out_schema)
    def func_input_transform1(df):
        return df
github pandera-dev / pandera / tests / test_pandera.py View on Github external
    @check_input(in_schema, "dataframe")
    @check_output(out_schema)
    def test_func4(x, dataframe):
        return dataframe.assign(f=["a", "b", "a"])
github pandera-dev / pandera / tests / test_pandera.py View on Github external
    @check_input(in_schema)
    @check_output(out_schema)
    def func_input_transform1(df):
        return df
github pandera-dev / pandera / tests / test_decorators.py View on Github external
        @check_input(in_schema, "df")
        @check_output(out_schema)
        def transform_secord_arg_with_dict_getter(self, x, df):
            return _transform_helper(df)
github pandera-dev / pandera / tests / test_decorators.py View on Github external
    @check_input(in_schema)
    @check_output(out_schema)
    def test_func1(dataframe, x):
        return dataframe.assign(f=["a", "b", "a"])