对于 https://github.com/wukan1986/expr_codegen/blob/main/expr_codegen/polars/code.py 上的get_groupby_from_tuple 方法里的排序。 如果输入的df 为lazyframe 这里排序没有意义,我测试了一下,不排序反而能提高速度。对于df为DataFrame的情况,sort 但不设置sorted ,polars实际无法感知到,sort在这里也是没有意义的。
对于 https://github.com/wukan1986/expr_codegen/blob/main/expr_codegen/polars/code.py 上的get_groupby_from_tuple 方法里的排序。
如果输入的df 为lazyframe 这里排序没有意义,我测试了一下,不排序反而能提高速度。对于df为DataFrame的情况,sort 但不设置sorted ,polars实际无法感知到,sort在这里也是没有意义的。