Skip to content

Commit a3ef98e

Browse files
Update documentation (#233)
- Change "khiops-python" to "Khiops Python library" - Eliminate old conda-build documentation - Removed obsolete conda doc - Other minor changes
1 parent 8c925cf commit a3ef98e

10 files changed

Lines changed: 79 additions & 93 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
**Notes:**
44
- Versioning: The versioning scheme depends on the Khiops version supported (first 3 digits) and
5-
a `khiops-python` correlative (4th digit).
5+
a Khiops Python Library correlative (4th digit).
66
- Example: 10.2.1.4 is the 5th version that supports khiops 10.2.1.
77
- Internals: Changes in *Internals* sections are unlikely to be of interest for data scientists.
88

@@ -71,10 +71,10 @@
7171

7272
## 10.2.0.0 - 2024-02-15
7373
Note: This release marks the open sourcing of Khiops:
74-
- The `khiops-python` replaces the old `pykhiops` package. We recommend to uninstall `pykhiops`
75-
before installing `khiops-python`. More information at the [Khiops website][khiops].
76-
- `khiops-python` uses a new four digit versioning convention.
77-
- The `khiops` conda package is available for many environments. See the [Khiops website][khiops]
74+
- The `khiops` package replaces the old `pykhiops` package. We recommend to uninstall
75+
`pykhiops` before installing `khiops`. More information at the [Khiops site][khiops].
76+
- The `khiops` package uses a new four digit versioning convention.
77+
- The `khiops` conda package is available for many environments. See the [Khiops site][khiops]
7878
for more information.
7979

8080
### Added

CONTRIBUTING.md

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# khiops-python Coding Guidelines
1+
# Khiops Python Library Coding Guidelines
22

33
## Quick Start
44
```bash
5-
# Make sure you are a member of the pyKhiops GitHub project and that you have set up the SSH keys
5+
# Make sure you are a member of the khiops-python GitHub project and that you have set up the SSH keys
66
# for Git
77

88
# Clone the repo
@@ -28,11 +28,11 @@ python -m unittest tests.test_sklearn.KhiopsSklearnParameterPassingTests
2828
## Coding Style
2929

3030
### Language
31-
`khiops-python` is coded in English (comments included).
31+
We code in English (comments included).
3232

3333
### Style Enforcement: Tools & Git Hooks
34-
The coding style of pyKhiops is almost PEP8 compliant. To enforce these guidelines we use three
35-
tools:
34+
The coding style of the Khiops Python library is almost PEP8 compliant. To enforce these guidelines
35+
we use three tools:
3636
- [Black](https://github.com/psf/black)
3737
- [isort](https://pycqa.github.io/isort/)
3838
- [Pylint](https://www.pylint.org/)
@@ -151,7 +151,7 @@ rebase before the last merge commit.
151151
A usual application of history rewriting is to eliminate commits named "Fix previous commit". In
152152
this case use `rebase` to rewrite the history as follows:
153153
```bash
154-
git rebase -i <REF-TO-FIX> # Usually REF-TO-FIX is either "develop", "HEAD~2" or a specific hash
154+
git rebase -i <ROOT-REF> # Usually ROOT-REF is either "dev", "HEAD~2" or a specific hash
155155
```
156156
to interactively move and squash fix commits with the `fixup` or `squash` operator. Usually this
157157
operation will make your feature branch diverge from `origin` (GitHub repo), so a `git push --force`
@@ -241,10 +241,16 @@ For development dependencies (eg. `black`, `isort`, `sphinx`, `wrapt`, `furo`) w
241241
carefree while still trying to not add too many dependencies.
242242

243243
## Versioning
244-
We follow a non-standard `MAJOR.MINOR.PATCH.INCREMENT[PRE_RELEASE]` versioning convention. The
244+
We follow a non-standard `MAJOR.MINOR.PATCH.INCREMENT[-PRE_RELEASE]` versioning convention. The
245245
first three numbers `MAJOR.MINOR.PATCH` are the latest Khiops version that is compatible with the
246-
package. The number `INCREMENT` indicates the evolution of `khiops-python` followed by an optional
247-
`[PRE_RELEASE]` version for alpha, beta and release candidate releases (eg. `b2`).
246+
package. The number `INCREMENT` indicates the evolution of the Khiops Python library followed by an
247+
optional `[-PRE_RELEASE]` version for alpha, beta and release candidate releases (eg. `b.2`).
248+
249+
**Important Note:** For the versions of packages we remove the dash `-` before the `PRE_RELEASE`
250+
atom to be compatible with the [Python version specifiers][python-version-spec], which is required
251+
by `pip` and `conda`.
252+
253+
[python-version-spec]: https://packaging.python.org/en/latest/specifications/version-specifiers/#version-specifiers
248254

249255
## Releases
250256

@@ -292,6 +298,3 @@ Checklist:
292298
To make a public release, you must execute the `Conda Package` CI workflow manually on a tag and
293299
specify the `khiops` anaconda channel for upload. These uploads do not overwrite any packages in
294300
this channel, so you must correct any mistake manually.
295-
296-
### Git Manipulations upon a Major Release
297-
The following is the check list to be done upon a major release:

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Khiops Python
1+
# Khiops Python Library
22

3-
**Khiops Python** is a Python library for the [Khiops AutoML suite][khiops].
3+
This is the repository of the **Khiops Python Library** for the [Khiops AutoML suite][khiops].
44

55
## Description
66
Khiops is a robust AutoML suite for constructing supervised models (classifiers, regressors and
@@ -31,7 +31,8 @@ Other install method are documented at the [Khiops website][khiops-install].
3131
[sklearn]: https://scikit-learn.org/stable
3232

3333
## Documentation
34-
The main documentation of the Khiops Python library is available [here][khiops-python-doc].
34+
The API Docs for the Khiops Python library are available [here][khiops-api-docs]. Other
35+
documentation (algorithms, installation, etc) may be found in the [Khiops site][khiops].
3536

3637
The library itself is documented with docstrings: for example to obtain help on the
3738
`train_predictor` function you can use:
@@ -54,7 +55,7 @@ Team: khiops.team@orange.com .
5455

5556
[khiops]: https://khiops.org
5657
[khiops-install]: https://khiops.org/setup
57-
[khiops-python-doc]: https://khiopsml.github.io/khiops-python
58+
[khiops-api-docs]: https://khiopsml.github.io/khiops-python
5859
[python]: https://www.python.org
5960
[pandas]: https://pandas.pydata.org
6061
[sklearn]: https://scikit-learn.org/stable

doc/tools/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Tools
22
=====
3-
These are auxiliary tools to the ``khiops-python`` installation.
3+
These are auxiliary tools for the Khiops Python library.
44

55
.. currentmodule:: khiops
66
.. autosummary::

khiops/core/internals/runner.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ def __init__(self):
360360
self._khiops_version = None
361361
self._samples_dir = None
362362

363-
# Whether to write the khiops-python version of the scenarios
363+
# Whether to write the Khiops Python library version of the scenarios
364364
# For development uses only
365365
self._write_version = True
366366

@@ -393,7 +393,7 @@ def root_temp_dir(self):
393393
r"""str: The runner's temporary directory
394394
395395
The temporary scenarios/templates and dictionary files created by
396-
khiops-python are stored here.
396+
the Khiops Python library are stored here.
397397
398398
Default value:
399399
- Windows: ``%TEMP%\khiops\python``
@@ -619,7 +619,7 @@ def _build_status_message(self):
619619
if caught_warnings is not None:
620620
warning_list += caught_warnings
621621

622-
status_msg = "khiops-python settings\n"
622+
status_msg = "Khiops Python library settings\n"
623623
status_msg += f"version : {khiops.__version__}\n"
624624
status_msg += f"runner class : {self.__class__.__name__}\n"
625625
status_msg += f"max cores : {self.max_cores}"
@@ -641,14 +641,14 @@ def print_status(self):
641641
try:
642642
status_msg, warning_list = self._build_status_message()
643643
except (KhiopsEnvironmentError, KhiopsRuntimeError) as error:
644-
print(f"khiops-python status KO: {error}")
644+
print(f"Khiops Python library status KO: {error}")
645645
return 1
646646

647647
# Print status details
648648
print(status_msg, end="")
649649

650650
# Print status
651-
print("khiops-python status OK", end="")
651+
print("Khiops Python library status OK", end="")
652652
if warning_list:
653653
print(", with warnings:")
654654
for warning in warning_list:
@@ -1415,21 +1415,21 @@ def _initialize_khiops_version(self):
14151415
else:
14161416
khiops_version_str, _, _, _ = _get_tool_info_khiops9(self, "khiops")
14171417
warnings.warn(
1418-
"Khiops version is earlier than 10.0; khiops-python will "
1418+
"Khiops version is earlier than 10.0; the Khiops Python library will "
14191419
f"run in legacy mode. Khiops path: {self._tool_path('khiops')}",
14201420
stacklevel=3,
14211421
)
14221422
self._khiops_version = KhiopsVersion(khiops_version_str)
14231423

1424-
# Warn if the khiops version is too far from the khiops-python version
1424+
# Warn if the khiops version is too far from the Khiops Python library version
14251425
compatible_khiops_version = khiops.get_compatible_khiops_version()
14261426
if self._khiops_version.major > compatible_khiops_version.major:
14271427
warnings.warn(
14281428
f"Khiops version '{self._khiops_version}' is ahead of "
1429-
f"the khiops-python version '{khiops.__version__}'. "
1429+
f"the Khiops Python library version '{khiops.__version__}'. "
14301430
"There may be compatibility errors and "
1431-
"we recommend you to update to the latest khiops-python version."
1432-
"Go to https://khiops.org for more information.",
1431+
"we recommend you to update to the latest Khiops Python "
1432+
"library version. See https://khiops.org for more information.",
14331433
stacklevel=3,
14341434
)
14351435

khiops/samples/samples.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1693,7 +1693,7 @@ def execute_samples(args):
16931693

16941694
# Print the execution title
16951695
if execution_samples:
1696-
print(f"khiops-python {khiops.__version__} running on Khiops ", end="")
1696+
print(f"Khiops Python library {khiops.__version__} running on Khiops ", end="")
16971697
print(f"{kh.get_khiops_version()}\n")
16981698
print(f"Sample datasets location: {kh.get_samples_dir()}")
16991699
print(f"{len(execution_samples)} sample(s) to execute\n")

khiops/samples/samples_sklearn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -975,7 +975,7 @@ def execute_samples(args):
975975

976976
# Print the execution title
977977
if execution_samples:
978-
print(f"khiops-python {khiops.__version__} running on Khiops ", end="")
978+
print(f"Khiops Python library {khiops.__version__} running on Khiops ", end="")
979979
print(f"{kh.get_khiops_version()}\n")
980980
print(f"Sample datasets location: {kh.get_samples_dir()}")
981981
print(f"{len(execution_samples)} sample(s) to execute\n")

0 commit comments

Comments
 (0)