mirror of
https://github.com/Doctorado-ML/STree.git
synced 2025-08-18 08:56:00 +00:00
Compare commits
3 Commits
Author | SHA1 | Date | |
---|---|---|---|
d46f544466
|
|||
79190ef2e1
|
|||
|
4f04e72670 |
11
Makefile
11
Makefile
@@ -1,6 +1,6 @@
|
|||||||
SHELL := /bin/bash
|
SHELL := /bin/bash
|
||||||
.DEFAULT_GOAL := help
|
.DEFAULT_GOAL := help
|
||||||
.PHONY: coverage deps help lint push test
|
.PHONY: coverage deps help lint push test doc build
|
||||||
|
|
||||||
coverage: ## Run tests with coverage
|
coverage: ## Run tests with coverage
|
||||||
coverage erase
|
coverage erase
|
||||||
@@ -24,6 +24,13 @@ test: ## Run tests
|
|||||||
doc: ## Update documentation
|
doc: ## Update documentation
|
||||||
make -C docs --makefile=Makefile html
|
make -C docs --makefile=Makefile html
|
||||||
|
|
||||||
|
build: ## Build package
|
||||||
|
rm -fr dist/*
|
||||||
|
python setup.py sdist bdist_wheel
|
||||||
|
|
||||||
|
doc-clean: ## Update documentation
|
||||||
|
make -C docs --makefile=Makefile clean
|
||||||
|
|
||||||
help: ## Show help message
|
help: ## Show help message
|
||||||
@IFS=$$'\n' ; \
|
@IFS=$$'\n' ; \
|
||||||
help_lines=(`fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##/:/'`); \
|
help_lines=(`fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##/:/'`); \
|
||||||
@@ -39,4 +46,4 @@ help: ## Show help message
|
|||||||
printf "%-20s %s" $$help_command ; \
|
printf "%-20s %s" $$help_command ; \
|
||||||
printf '\033[0m'; \
|
printf '\033[0m'; \
|
||||||
printf "%s\n" $$help_info; \
|
printf "%s\n" $$help_info; \
|
||||||
done
|
done
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||

|

|
||||||
[](https://codecov.io/gh/doctorado-ml/stree)
|
[](https://codecov.io/gh/doctorado-ml/stree)
|
||||||
[](https://www.codacy.com/gh/Doctorado-ML/STree?utm_source=github.com&utm_medium=referral&utm_content=Doctorado-ML/STree&utm_campaign=Badge_Grade)
|
[](https://www.codacy.com/gh/Doctorado-ML/STree?utm_source=github.com&utm_medium=referral&utm_content=Doctorado-ML/STree&utm_campaign=Badge_Grade)
|
||||||
|
[](https://lgtm.com/projects/g/Doctorado-ML/STree/context:python)
|
||||||
|
|
||||||
# Stree
|
# STree
|
||||||
|
|
||||||
Oblique Tree classifier based on SVM nodes. The nodes are built and splitted with sklearn SVC models. Stree is a sklearn estimator and can be integrated in pipelines, grid searches, etc.
|
Oblique Tree classifier based on SVM nodes. The nodes are built and splitted with sklearn SVC models. Stree is a sklearn estimator and can be integrated in pipelines, grid searches, etc.
|
||||||
|
|
||||||
|
@@ -1,3 +1,4 @@
|
|||||||
sphinx
|
sphinx
|
||||||
sphinx-rtd-theme
|
sphinx-rtd-theme
|
||||||
myst-parser
|
myst-parser
|
||||||
|
git+https://github.com/doctorado-ml/stree
|
||||||
|
@@ -12,6 +12,7 @@
|
|||||||
#
|
#
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
|
import stree
|
||||||
|
|
||||||
sys.path.insert(0, os.path.abspath("../../stree/"))
|
sys.path.insert(0, os.path.abspath("../../stree/"))
|
||||||
|
|
||||||
@@ -23,7 +24,8 @@ copyright = "2020 - 2021, Ricardo Montañana Gómez"
|
|||||||
author = "Ricardo Montañana Gómez"
|
author = "Ricardo Montañana Gómez"
|
||||||
|
|
||||||
# The full version, including alpha/beta/rc tags
|
# The full version, including alpha/beta/rc tags
|
||||||
release = "1.0"
|
version = stree.__version__
|
||||||
|
release = version
|
||||||
|
|
||||||
|
|
||||||
# -- General configuration ---------------------------------------------------
|
# -- General configuration ---------------------------------------------------
|
||||||
|
@@ -1,8 +1,9 @@
|
|||||||
# Stree
|
# STree
|
||||||
|
|
||||||
[](https://app.codeship.com/projects/399170)
|
[](https://app.codeship.com/projects/399170)
|
||||||
[](https://codecov.io/gh/doctorado-ml/stree)
|
[](https://codecov.io/gh/doctorado-ml/stree)
|
||||||
[](https://www.codacy.com/gh/Doctorado-ML/STree?utm_source=github.com&utm_medium=referral&utm_content=Doctorado-ML/STree&utm_campaign=Badge_Grade)
|
[](https://www.codacy.com/gh/Doctorado-ML/STree?utm_source=github.com&utm_medium=referral&utm_content=Doctorado-ML/STree&utm_campaign=Badge_Grade)
|
||||||
|
[](https://lgtm.com/projects/g/Doctorado-ML/STree/context:python)
|
||||||
|
|
||||||
Oblique Tree classifier based on SVM nodes. The nodes are built and splitted with sklearn SVC models. Stree is a sklearn estimator and can be integrated in pipelines, grid searches, etc.
|
Oblique Tree classifier based on SVM nodes. The nodes are built and splitted with sklearn SVC models. Stree is a sklearn estimator and can be integrated in pipelines, grid searches, etc.
|
||||||
|
|
||||||
|
27
setup.py
27
setup.py
@@ -1,5 +1,4 @@
|
|||||||
import setuptools
|
import setuptools
|
||||||
import stree
|
|
||||||
|
|
||||||
|
|
||||||
def readme():
|
def readme():
|
||||||
@@ -7,11 +6,23 @@ def readme():
|
|||||||
return f.read()
|
return f.read()
|
||||||
|
|
||||||
|
|
||||||
VERSION = stree.__version__
|
def get_data(field):
|
||||||
|
item = ""
|
||||||
|
with open("stree/__init__.py") as f:
|
||||||
|
for line in f.readlines():
|
||||||
|
if line.startswith(f"__{field}__"):
|
||||||
|
delim = '"' if '"' in line else "'"
|
||||||
|
item = line.split(delim)[1]
|
||||||
|
break
|
||||||
|
else:
|
||||||
|
raise RuntimeError(f"Unable to find {field} string.")
|
||||||
|
return item
|
||||||
|
|
||||||
|
|
||||||
setuptools.setup(
|
setuptools.setup(
|
||||||
name="STree",
|
name="STree",
|
||||||
version=stree.__version__,
|
version=get_data("version"),
|
||||||
license=stree.__license__,
|
license=get_data("license"),
|
||||||
description="Oblique decision tree with svm nodes",
|
description="Oblique decision tree with svm nodes",
|
||||||
long_description=readme(),
|
long_description=readme(),
|
||||||
long_description_content_type="text/markdown",
|
long_description_content_type="text/markdown",
|
||||||
@@ -21,19 +32,19 @@ setuptools.setup(
|
|||||||
"Code": "https://github.com/Doctorado-ML/STree",
|
"Code": "https://github.com/Doctorado-ML/STree",
|
||||||
"Documentation": "https://stree.readthedocs.io/en/latest/index.html",
|
"Documentation": "https://stree.readthedocs.io/en/latest/index.html",
|
||||||
},
|
},
|
||||||
author=stree.__author__,
|
author=get_data("author"),
|
||||||
author_email=stree.__author_email__,
|
author_email=get_data("author_email"),
|
||||||
keywords="scikit-learn oblique-classifier oblique-decision-tree decision-\
|
keywords="scikit-learn oblique-classifier oblique-decision-tree decision-\
|
||||||
tree svm svc",
|
tree svm svc",
|
||||||
classifiers=[
|
classifiers=[
|
||||||
"Development Status :: 5 - Production/Stable",
|
"Development Status :: 5 - Production/Stable",
|
||||||
"License :: OSI Approved :: " + stree.__license__,
|
"License :: OSI Approved :: " + get_data("license"),
|
||||||
"Programming Language :: Python :: 3.8",
|
"Programming Language :: Python :: 3.8",
|
||||||
"Natural Language :: English",
|
"Natural Language :: English",
|
||||||
"Topic :: Scientific/Engineering :: Artificial Intelligence",
|
"Topic :: Scientific/Engineering :: Artificial Intelligence",
|
||||||
"Intended Audience :: Science/Research",
|
"Intended Audience :: Science/Research",
|
||||||
],
|
],
|
||||||
install_requires=["scikit-learn", "numpy", "ipympl"],
|
install_requires=["scikit-learn", "numpy"],
|
||||||
test_suite="stree.tests",
|
test_suite="stree.tests",
|
||||||
zip_safe=False,
|
zip_safe=False,
|
||||||
)
|
)
|
||||||
|
10
stree/.readthedocs.yaml
Normal file
10
stree/.readthedocs.yaml
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
version: 2
|
||||||
|
|
||||||
|
sphinx:
|
||||||
|
configuration: docs/source/conf.py
|
||||||
|
|
||||||
|
python:
|
||||||
|
version: 3.8
|
||||||
|
install:
|
||||||
|
- requirements: requirements.txt
|
||||||
|
- requirements: docs/requirements.txt
|
Reference in New Issue
Block a user