Skip to content

CI,STYLE: GH38802 narrow down list of ignored words #38820

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions pandas/core/arrays/sparse/accessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,18 +333,18 @@ def to_coo(self):
if isinstance(dtype, SparseDtype):
dtype = dtype.subtype

cols, rows, datas = [], [], []
cols, rows, data = [], [], []
for col, name in enumerate(self._parent):
s = self._parent[name]
row = s.array.sp_index.to_int_index().indices
cols.append(np.repeat(col, len(row)))
rows.append(row)
datas.append(s.array.sp_values.astype(dtype, copy=False))
data.append(s.array.sp_values.astype(dtype, copy=False))

cols = np.concatenate(cols)
rows = np.concatenate(rows)
datas = np.concatenate(datas)
return coo_matrix((datas, (rows, cols)), shape=self._parent.shape)
data = np.concatenate(data)
return coo_matrix((data, (rows, cols)), shape=self._parent.shape)

@property
def density(self) -> float:
Expand Down
10 changes: 5 additions & 5 deletions pandas/core/strings/accessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -1547,10 +1547,10 @@ def slice(self, start=None, stop=None, step=None):

Examples
--------
>>> s = pd.Series(["koala", "fox", "chameleon"])
>>> s = pd.Series(["koala", "nox", "chameleon"])
>>> s
0 koala
1 fox
1 nox
2 chameleon
dtype: object

Expand All @@ -1568,19 +1568,19 @@ def slice(self, start=None, stop=None, step=None):

>>> s.str.slice(stop=2)
0 ko
1 fo
1 no
2 ch
dtype: object

>>> s.str.slice(step=2)
0 kaa
1 fx
1 nx
2 caeen
dtype: object

>>> s.str.slice(start=0, stop=5, step=3)
0 kl
1 f
1 n
2 cm
dtype: object

Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ filterwarnings =
junit_family=xunit2

[codespell]
ignore-words-list=ba,blocs,coo,datas,fo,hist,nd,ser
ignore-words-list=ba,blocs,coo,hist,nd,ser

[coverage:run]
branch = False
Expand Down