Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 34a983f

Browse filesBrowse files
committed
Added examples file
1 parent 82f69b6 commit 34a983f
Copy full SHA for 34a983f

File tree

Expand file treeCollapse file tree

4 files changed

+14
-195
lines changed
Filter options
Expand file treeCollapse file tree

4 files changed

+14
-195
lines changed

‎sklearn/neighbors/__init__.py

Copy file name to clipboardExpand all lines: sklearn/neighbors/__init__.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"""
55

66
from ._ball_tree import BallTree
7-
from ._kd_tree import KDTree
7+
from ._kd_tree import KDTree, Test
88
from ._dist_metrics import DistanceMetric
99
from ._graph import kneighbors_graph, radius_neighbors_graph
1010
from ._graph import KNeighborsTransformer, RadiusNeighborsTransformer
@@ -21,6 +21,7 @@
2121
__all__ = ['BallTree',
2222
'DistanceMetric',
2323
'KDTree',
24+
'Test',
2425
'KNeighborsClassifier',
2526
'KNeighborsRegressor',
2627
'KNeighborsTransformer',

‎sklearn/neighbors/_kd_tree.pyx

Copy file name to clipboardExpand all lines: sklearn/neighbors/_kd_tree.pyx
+5-1Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# written for the scikit-learn project
88
# License: BSD
99

10-
__all__ = ['KDTree']
10+
__all__ = ['KDTree', 'Test']
1111

1212
DOC_DICT = {'BinaryTree': 'KDTree', 'binary_tree': 'kd_tree'}
1313

@@ -22,6 +22,10 @@ cdef class KDTree(BinaryTree):
2222
__doc__ = CLASS_DOC.format(**DOC_DICT)
2323
pass
2424

25+
class Test:
26+
def __init__(self):
27+
pass
28+
2529

2630
#----------------------------------------------------------------------
2731
# The functions below specialized the Binary Tree as a KD Tree

‎sklearn/neighbors/_subsampled.py

Copy file name to clipboardExpand all lines: sklearn/neighbors/_subsampled.py
-193Lines changed: 0 additions & 193 deletions
This file was deleted.

‎sklearn/neighbors/setup.py

Copy file name to clipboardExpand all lines: sklearn/neighbors/setup.py
+7Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,18 @@ def configuration(parent_package='', top_path=None):
3131
sources=['_typedefs.pyx'],
3232
include_dirs=[numpy.get_include()],
3333
libraries=libraries)
34+
3435
config.add_extension("_quad_tree",
3536
sources=["_quad_tree.pyx"],
3637
include_dirs=[numpy.get_include()],
3738
libraries=libraries)
3839

40+
config.add_extension('_subsampled',
41+
sources=['_subsampled.pyx'],
42+
include_dirs=[numpy.get_include()],
43+
libraries=libraries,
44+
language="c++")
45+
3946
config.add_subpackage('tests')
4047

4148
return config

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.