Skip to content

Commit d6e562d

Browse files
Merge pull request #1241 from mindsdb/staging
Release 24.12.1.0
2 parents 44b3fdf + 3a9d7f1 commit d6e562d

File tree

5 files changed

+140
-155
lines changed

5 files changed

+140
-155
lines changed

.github/workflows/lightwood.yml

+45-46
Original file line numberDiff line numberDiff line change
@@ -7,64 +7,63 @@ on:
77
- stable
88
- staging
99
release:
10-
types: [ published ]
11-
10+
types: [published]
1211

1312
jobs:
1413
test:
1514
runs-on: ${{ matrix.os }}
1615
strategy:
1716
matrix:
1817
os: [ubuntu-latest]
19-
python-version: ["3.8","3.9","3.10","3.11"]
18+
python-version: ["3.9", "3.10", "3.11"]
2019
steps:
21-
- uses: actions/checkout@v2
22-
- name: Set up Python ${{ matrix.python-version }}
23-
uses: actions/setup-python@v2
24-
with:
25-
python-version: ${{ matrix.python-version }}
26-
- name: Install dependencies
27-
run: |
28-
python -m pip install --upgrade pip
29-
python -m pip install setuptools poetry
30-
poetry install -E dev -E image
31-
- name: Install dependencies OSX
32-
run: |
33-
if [ "$RUNNER_OS" == "macOS" ]; then
34-
brew install libomp;
35-
fi
36-
shell: bash
37-
env:
38-
CHECK_FOR_UPDATES: False
39-
- name: Lint with flake8
40-
run: |
41-
poetry run python -m flake8 .
42-
- name: Test with unittest
43-
run: |
44-
# Run all the "standard" tests
45-
poetry run python -m unittest discover tests
20+
- uses: actions/checkout@v2
21+
- name: Set up Python ${{ matrix.python-version }}
22+
uses: actions/setup-python@v2
23+
with:
24+
python-version: ${{ matrix.python-version }}
25+
- name: Install dependencies
26+
run: |
27+
python -m pip install --upgrade pip
28+
python -m pip install setuptools poetry
29+
poetry install -E dev -E image
30+
- name: Install dependencies OSX
31+
run: |
32+
if [ "$RUNNER_OS" == "macOS" ]; then
33+
brew install libomp;
34+
fi
35+
shell: bash
36+
env:
37+
CHECK_FOR_UPDATES: False
38+
- name: Lint with flake8
39+
run: |
40+
poetry run python -m flake8 .
41+
- name: Test with unittest
42+
run: |
43+
# Run all the "standard" tests
44+
poetry run python -m unittest discover tests
4645
4746
deploy:
4847
runs-on: ubuntu-latest
4948
environment: PublishCI
5049
needs: test
5150
if: github.ref == 'refs/heads/stable' || github.event_name == 'release'
5251
steps:
53-
- uses: actions/checkout@v2
54-
- name: Set up Python
55-
uses: actions/setup-python@v2
56-
with:
57-
python-version: '3.8'
58-
- name: Install dependencies
59-
run: |
60-
python -m pip install --upgrade pip
61-
pip install poetry
62-
- name: Build
63-
run: poetry build
64-
- name: Publish
65-
env:
66-
POETRY_HTTP_BASIC_PYPI_USERNAME: __token__
67-
POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
68-
run: |
69-
poetry publish --dry-run
70-
poetry publish
52+
- uses: actions/checkout@v2
53+
- name: Set up Python
54+
uses: actions/setup-python@v2
55+
with:
56+
python-version: "3.10"
57+
- name: Install dependencies
58+
run: |
59+
python -m pip install --upgrade pip
60+
pip install poetry
61+
- name: Build
62+
run: poetry build
63+
- name: Publish
64+
env:
65+
POETRY_HTTP_BASIC_PYPI_USERNAME: __token__
66+
POETRY_HTTP_BASIC_PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
67+
run: |
68+
poetry publish --dry-run
69+
poetry publish

lightwood/analysis/nc/calibrate.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def analyze(self, info: Dict[str, object], **kwargs) -> Dict[str, object]:
5959
all_classes = np.array([ns.encoded_val_data.encoders[ns.target].rev_map[idx] for idx in class_keys])
6060

6161
if data_type != dtype.tags:
62-
enc = OneHotEncoder(sparse=False, handle_unknown='ignore')
62+
enc = OneHotEncoder(sparse_output=False, handle_unknown='ignore')
6363
enc.fit(all_classes.reshape(-1, 1))
6464
output['label_encoders'] = enc # needed to repr cat labels inside nonconformist
6565
else:

lightwood/encoder/helpers.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class CatNormalizer:
4545
def __init__(self, encoder_class='one_hot'):
4646
self.encoder_class = encoder_class
4747
if encoder_class == 'one_hot':
48-
self.scaler = OneHotEncoder(sparse=False, handle_unknown='ignore')
48+
self.scaler = OneHotEncoder(sparse_output=False, handle_unknown='ignore')
4949
else:
5050
self.scaler = OrdinalEncoder()
5151

0 commit comments

Comments
 (0)