Skip to content

Commit

Permalink
remove self in validation
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaolong0728 committed Nov 13, 2024
1 parent ed8615a commit 9c9f14d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions common_utils/views_stepshifter_darts/validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
logger = logging.getLogger(__name__)


def dataframe_is_right_format(self, dataframe: pd.DataFrame):
def dataframe_is_right_format(dataframe: pd.DataFrame):
try:
assert len(dataframe.index.levels) == 2
# print("The dataframe has a two-level index")
Expand Down Expand Up @@ -39,7 +39,7 @@ def dataframe_is_right_format(self, dataframe: pd.DataFrame):

def views_validate(fn):
@functools.wraps(fn)
def inner(self, *args,**kwargs):
dataframe_is_right_format(self, args[-1])
return fn(self, *args, **kwargs)
def inner(*args,**kwargs):
dataframe_is_right_format(args[-1])
return fn(*args, **kwargs)
return inner

0 comments on commit 9c9f14d

Please sign in to comment.