8000 Fix typos (#9095) · scikit-learn/scikit-learn@93871e2 · GitHub
[go: up one dir, main page]

Skip to content

Commit 93871e2

Browse files
taehoonleelesteve
authored andcommitted
Fix typos (#9095)
1 parent 440c77b commit 93871e2

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

doc/modules/neural_networks_unsupervised.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ The graphical model of an RBM is a fully-connected bipartite graph.
5353
The nodes are random variables whose states depend on the state of the other
5454
nodes they are connected to. The model is therefore parameterized by the
5555
weights of the connections, as well as one intercept (bias) term for each
56-
visible and hidden unit, ommited from the image for simplicity.
56+
visible and hidden unit, omitted from the image for simplicity.
5757

5858
The energy function measures the quality of a joint assignment:
5959

doc/whats_new.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -753,7 +753,7 @@ Classifiers and Regressors
753753
:issue:`5291` by `Manoj Kumar`_.
754754

755755
- Added the :class:`multioutput.MultiOutputRegressor` meta-estimator. It
756-
converts single output regressors to multi-ouput regressors by fitting
756+
converts single output regressors to multi-output regressors by fitting
757757
one regressor per output. By :user:`Tim Head <betatim>`.
758758

759759
Other estimators

sklearn/cluster/_k_means_elkan.pyx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ from ..metrics import euclidean_distances
1818
from ._k_means import _centers_dense
1919

2020

21-
cdef floating euclidian_dist(floating* a, floating* b, int n_features) nogil:
21+
cdef floating euclidean_dist(floating* a, floating* b, int n_features) nogil:
2222
cdef floating result, tmp
2323
result = 0
2424
cdef int i
@@ -89,12 +89,12 @@ cdef update_labels_distances_inplace(
8989
# assign first cluster center
9090
c_x = 0
9191
x = X + sample * n_features
92-
d_c = euclidian_dist(x, centers, n_features)
92+
d_c = euclidean_dist(x, centers, n_features)
9393
lower_bounds[sample, 0] = d_c
9494
for j in range(1, n_clusters):
9595
if d_c > center_half_distances[c_x, j]:
9696
c = centers + j * n_features
97-
dist = euclidian_dist(x, c, n_features)
97+
dist = euclidean_dist(x, c, n_features)
9898
lower_bounds[sample, j] = dist
9999
if dist < d_c:
100100
d_c = dist
@@ -197,7 +197,7 @@ def k_means_elkan(np.ndarray[floating, ndim=2, mode='c'] X_, int n_clusters,
197197
# Recompute the upper bound by calculating the actual distance
198198
# between the sample and label.
199199
if not bounds_tight[point_index]:
200-
upper_bound = euclidian_dist(x_p, centers_p + label * n_features, n_features)
200+
upper_bound = euclidean_dist(x_p, centers_p + label * n_features, n_features)
201201
lower_bounds[point_index, label] = upper_bound
202202
bounds_tight[point_index] = 1
203203

@@ -206,7 +206,7 @@ def k_means_elkan(np.ndarray[floating, ndim=2, mode='c'] X_, int n_clusters,
206206
# distance, reassign labels.
207207
if (upper_bound > lower_bounds[point_index, center_index]
208208
or (upper_bound > center_half_distances[label, center_index])):
209-
distance = euclidian_dist(x_p, centers_p + center_index * n_features, n_features)
209+
distance = euclidean_dist(x_p, centers_p + center_index * n_features, n_features)
210210
lower_bounds[point_index, center_index] = distance
211211
if distance < upper_bound:
212212
label = center_index

sklearn/manifold/_barnes_hut_tsne.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ cdef struct Node:
8080
cdef struct Tree:
8181
# Holds a pointer to the root node
8282
Node* root_node
83-
# Number of dimensions in the ouput
83+
# Number of dimensions in the output
8484
int n_dimensions
8585
# Total number of cells
8686
long n_cells

sklearn/tests/test_multioutput.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ def test_multi_output_classification_partial_fit():
193193
assert_array_equal(sgd_linear_clf.predict(X), second_predictions[:, i])
194194

195195

196-
def test_mutli_output_classifiation_partial_fit_no_first_classes_exception():
196+
def test_multi_output_classifiation_partial_fit_no_first_classes_exception():
197197
sgd_linear_clf = SGDClassifier(loss='log', random_state=1)
198198
multi_target_linear = MultiOutputClassifier(sgd_linear_clf)
199199
assert_raises_regex(ValueError, "classes must be passed on the first call "

0 commit comments

Comments
 (0)
0