Skip to content

Commit

Permalink
Fix style check again
Browse files Browse the repository at this point in the history
  • Loading branch information
ttnghia committed Mar 16, 2021
1 parent cda7d3b commit dafda23
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 12 deletions.
13 changes: 5 additions & 8 deletions python/cudf/cudf/core/column/string.py
Original file line number Diff line number Diff line change
Expand Up @@ -342,9 +342,7 @@ def byte_count(self) -> ParentType:
2 11
dtype: int32
"""
return self._return_or_inplace(
cpp_count_bytes(self._column),
)
return self._return_or_inplace(cpp_count_bytes(self._column),)

@overload
def cat(self, sep: str = None, na_rep: str = None) -> str:
Expand Down Expand Up @@ -446,9 +444,7 @@ def cat(self, others=None, sep=None, na_rep=None):

if others is None:
data = cpp_join(
self._column,
cudf.Scalar(sep),
cudf.Scalar(na_rep, "str"),
self._column, cudf.Scalar(sep), cudf.Scalar(na_rep, "str"),
)
else:
other_cols = _get_cols_list(self._parent, others)
Expand Down Expand Up @@ -4510,7 +4506,7 @@ def is_consonant(self, position) -> ParentType:
0 True
1 False
dtype: bool
"""
"""
ltype = LetterType.CONSONANT

if can_convert_to_column(position):
Expand Down Expand Up @@ -4647,7 +4643,8 @@ def _expected_types_format(types):


class StringColumn(column.ColumnBase):
"""Implements operations for Columns of String type"""
"""Implements operations for Columns of String type
"""

_start_offset: Optional[int]
_end_offset: Optional[int]
Expand Down
6 changes: 2 additions & 4 deletions python/cudf/cudf/core/tools/datetimes.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,14 +316,12 @@ def _process_col(col, unit, dayfirst, infer_datetime_format, format):
else:
if infer_datetime_format and format is None:
format = column.datetime.infer_format(
element=col[0],
dayfirst=dayfirst,
element=col[0], dayfirst=dayfirst,
)
elif format is None:
format = column.datetime.infer_format(element=col[0])
col = col.as_datetime_column(
dtype=_unit_dtype_map[unit],
format=format,
dtype=_unit_dtype_map[unit], format=format,
)
return col

Expand Down

0 comments on commit dafda23

Please sign in to comment.