Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
luochang212 committed May 24, 2024
1 parent 0a2506a commit 7a72dfd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion .github/workflows/nox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install nox
pip install flake8-import-order
- name: Run nox
run: nox --non-interactive --error-on-missing-interpreter
3 changes: 2 additions & 1 deletion tests/test_preprocessing.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
from flameai.preprocessing import DataLoader, gen_scale_pos_weight, label_encoder
import numpy as np
import pandas as pd


def test_label_encoder():
df = pd.DataFrame({'a': ['a', 'b', 'c', 'a', 'b', 'c'],
'b': [1, 2, 3, 2, 1, 0]})
result = label_encoder(df)
result = label_encoder(df).reset_index(drop=True)
assert result.equals(pd.DataFrame({'a': [0, 1, 2, 0, 1, 2],
'b': [1, 2, 3, 2, 1, 0]}))

Expand Down

0 comments on commit 7a72dfd

Please sign in to comment.