Skip to content

Commit 1bfc030

Browse files
committed
Merge remote-tracking branch 'upstream/master' into excel-read-shared-init-to-baseclass
# Conflicts: # pandas/io/excel/_base.py # pandas/io/excel/_xlrd.py
2 parents d0188ba + 64104ec commit 1bfc030

File tree

755 files changed

+16682
-16452
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

755 files changed

+16682
-16452
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,11 @@ dist
6161
.coverage
6262
coverage.xml
6363
coverage_html_report
64+
.mypy_cache
6465
*.pytest_cache
6566
# hypothesis test database
6667
.hypothesis/
68+
__pycache__
6769

6870
# OS generated files #
6971
######################

.travis.yml

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
sudo: false
22
language: python
3-
# Default Python version is usually 2.7
43
python: 3.5
54

65
# To turn off cached cython files and compiler cache
@@ -36,21 +35,13 @@ matrix:
3635
env:
3736
- JOB="3.7" ENV_FILE="ci/deps/travis-37.yaml" PATTERN="(not slow and not network)"
3837

39-
- dist: trusty
40-
env:
41-
- JOB="2.7" ENV_FILE="ci/deps/travis-27.yaml" PATTERN="(not slow or (single and db))"
42-
addons:
43-
apt:
44-
packages:
45-
- python-gtk2
46-
4738
- dist: trusty
4839
env:
4940
- JOB="3.6, locale" ENV_FILE="ci/deps/travis-36-locale.yaml" PATTERN="((not slow and not network) or (single and db))" LOCALE_OVERRIDE="zh_CN.UTF-8"
5041

5142
- dist: trusty
5243
env:
53-
- JOB="3.6, coverage" ENV_FILE="ci/deps/travis-36.yaml" PATTERN="((not slow and not network) or (single and db))" PANDAS_TESTING_MODE="deprecate" COVERAGE=true
44+
- JOB="3.6, coverage" ENV_FILE="ci/deps/travis-36-cov.yaml" PATTERN="((not slow and not network) or (single and db))" PANDAS_TESTING_MODE="deprecate" COVERAGE=true
5445

5546
# In allow_failures
5647
- dist: trusty
@@ -91,15 +82,10 @@ before_install:
9182
install:
9283
- echo "install start"
9384
- ci/prep_cython_cache.sh
94-
- ci/install_travis.sh
85+
- ci/setup_env.sh
9586
- ci/submit_cython_cache.sh
9687
- echo "install done"
9788

98-
before_script:
99-
- ci/install_db_travis.sh
100-
- export DISPLAY=":99.0"
101-
- ci/before_script_travis.sh
102-
10389
script:
10490
- echo "script start"
10591
- source activate pandas-dev

LICENSES/SIX

Lines changed: 0 additions & 21 deletions
This file was deleted.

README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@
2626
<td>Package Status</td>
2727
<td>
2828
<a href="https://pypi.org/project/pandas/">
29-
<img src="https://img.shields.io/pypi/status/pandas.svg" alt="status" /></td>
29+
<img src="https://img.shields.io/pypi/status/pandas.svg" alt="status" />
3030
</a>
31+
</td>
3132
</tr>
3233
<tr>
3334
<td>License</td>
@@ -73,8 +74,8 @@
7374
<td>Gitter</td>
7475
<td>
7576
<a href="https://gitter.im/pydata/pandas">
76-
<img src="https://badges.gitter.im/Join%20Chat.svg"
77-
</a>
77+
<img src="https://badges.gitter.im/Join%20Chat.svg" />
78+
</a>
7879
</td>
7980
</tr>
8081
</table>
@@ -163,9 +164,9 @@ pip install pandas
163164
```
164165

165166
## Dependencies
166-
- [NumPy](https://www.numpy.org): 1.12.0 or higher
167+
- [NumPy](https://www.numpy.org): 1.13.3 or higher
167168
- [python-dateutil](https://labix.org/python-dateutil): 2.5.0 or higher
168-
- [pytz](https://pythonhosted.org/pytz): 2011k or higher
169+
- [pytz](https://pythonhosted.org/pytz): 2015.4 or higher
169170

170171
See the [full installation instructions](https://pandas.pydata.org/pandas-docs/stable/install.html#dependencies)
171172
for recommended and optional dependencies.

asv_bench/benchmarks/algorithms.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
pass
1414

1515

16-
class Factorize(object):
16+
class Factorize:
1717

1818
params = [[True, False], ['int', 'uint', 'float', 'string']]
1919
param_names = ['sort', 'dtype']
@@ -30,7 +30,7 @@ def time_factorize(self, sort, dtype):
3030
self.idx.factorize(sort=sort)
3131

3232

33-
class FactorizeUnique(object):
33+
class FactorizeUnique:
3434

3535
params = [[True, False], ['int', 'uint', 'float', 'string']]
3636
param_names = ['sort', 'dtype']
@@ -48,7 +48,7 @@ def time_factorize(self, sort, dtype):
4848
self.idx.factorize(sort=sort)
4949

5050

51-
class Duplicated(object):
51+
class Duplicated:
5252

5353
params = [['first', 'last', False], ['int', 'uint', 'float', 'string']]
5454
param_names = ['keep', 'dtype']
@@ -67,7 +67,7 @@ def time_duplicated(self, keep, dtype):
6767
self.idx.duplicated(keep=keep)
6868

6969

70-
class DuplicatedUniqueIndex(object):
70+
class DuplicatedUniqueIndex:
7171

7272
params = ['int', 'uint', 'float', 'string']
7373
param_names = ['dtype']
@@ -86,7 +86,7 @@ def time_duplicated_unique(self, dtype):
8686
self.idx.duplicated()
8787

8888

89-
class Hashing(object):
89+
class Hashing:
9090

9191
def setup_cache(self):
9292
N = 10**5
@@ -124,7 +124,7 @@ def time_series_dates(self, df):
124124
hashing.hash_pandas_object(df['dates'])
125125

126126

127-
class Quantile(object):
127+
class Quantile:
128128
params = [[0, 0.5, 1],
129129
['linear', 'nearest', 'lower', 'higher', 'midpoint'],
130130
['float', 'int', 'uint']]

asv_bench/benchmarks/attrs_caching.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from pandas.util.decorators import cache_readonly
77

88

9-
class DataFrameAttributes(object):
9+
class DataFrameAttributes:
1010

1111
def setup(self):
1212
self.df = DataFrame(np.random.randn(10, 6))
@@ -19,7 +19,7 @@ def time_set_index(self):
1919
self.df.index = self.cur_index
2020

2121

22-
class CacheReadonly(object):
22+
class CacheReadonly:
2323

2424
def setup(self):
2525

asv_bench/benchmarks/binary_ops.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import pandas.computation.expressions as expr
88

99

10-
class Ops(object):
10+
class Ops:
1111

1212
params = [[True, False], ['default', 1]]
1313
param_names = ['use_numexpr', 'threads']
@@ -38,7 +38,7 @@ def teardown(self, use_numexpr, threads):
3838
expr.set_numexpr_threads()
3939

4040

41-
class Ops2(object):
41+
class Ops2:
4242

4343
def setup(self):
4444
N = 10**3
@@ -88,7 +88,7 @@ def time_frame_series_dot(self):
8888
self.df.dot(self.s)
8989

9090

91-
class Timeseries(object):
91+
class Timeseries:
9292

9393
params = [None, 'US/Eastern']
9494
param_names = ['tz']
@@ -114,7 +114,7 @@ def time_timestamp_ops_diff_with_shift(self, tz):
114114
self.s - self.s.shift()
115115

116116

117-
class AddOverflowScalar(object):
117+
class AddOverflowScalar:
118118

119119
params = [1, -1, 0]
120120
param_names = ['scalar']
@@ -127,7 +127,7 @@ def time_add_overflow_scalar(self, scalar):
127127
checked_add_with_arr(self.arr, scalar)
128128

129129

130-
class AddOverflowArray(object):
130+
class AddOverflowArray:
131131

132132
def setup(self):
133133
N = 10**6

asv_bench/benchmarks/categoricals.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
pass
1313

1414

15-
class Concat(object):
15+
class Concat:
1616

1717
def setup(self):
1818
N = 10**5
@@ -28,7 +28,7 @@ def time_union(self):
2828
union_categoricals([self.a, self.b])
2929

3030

31-
class Constructor(object):
31+
class Constructor:
3232

3333
def setup(self):
3434
N = 10**5
@@ -77,7 +77,7 @@ def time_existing_series(self):
7777
pd.Categorical(self.series)
7878

7979

80-
class ValueCounts(object):
80+
class ValueCounts:
8181

8282
params = [True, False]
8383
param_names = ['dropna']
@@ -92,7 +92,7 @@ def time_value_counts(self, dropna):
9292
self.ts.value_counts(dropna=dropna)
9393

9494

95-
class Repr(object):
95+
class Repr:
9696

9797
def setup(self):
9898
self.sel = pd.Series(['s1234']).astype('category')
@@ -101,7 +101,7 @@ def time_rendering(self):
101101
str(self.sel)
102102

103103

104-
class SetCategories(object):
104+
class SetCategories:
105105

106106
def setup(self):
107107
n = 5 * 10**5
@@ -113,7 +113,7 @@ def time_set_categories(self):
113113
self.ts.cat.set_categories(self.ts.cat.categories[::2])
114114

115115

116-
class RemoveCategories(object):
116+
class RemoveCategories:
117117

118118
def setup(self):
119119
n = 5 * 10**5
@@ -125,7 +125,7 @@ def time_remove_categories(self):
125125
self.ts.cat.remove_categories(self.ts.cat.categories[::2])
126126

127127

128-
class Rank(object):
128+
class Rank:
129129

130130
def setup(self):
131131
N = 10**5
@@ -162,7 +162,7 @@ def time_rank_int_cat_ordered(self):
162162
self.s_int_cat_ordered.rank()
163163

164164

165-
class Isin(object):
165+
class Isin:
166166

167167
params = ['object', 'int64']
168168
param_names = ['dtype']
@@ -181,7 +181,7 @@ def time_isin_categorical(self, dtype):
181181
self.series.isin(self.sample)
182182

183183

184-
class IsMonotonic(object):
184+
class IsMonotonic:
185185

186186
def setup(self):
187187
N = 1000
@@ -201,7 +201,7 @@ def time_categorical_series_is_monotonic_decreasing(self):
201201
self.s.is_monotonic_decreasing
202202

203203

204-
class Contains(object):
204+
class Contains:
205205

206206
def setup(self):
207207
N = 10**5
@@ -216,7 +216,7 @@ def time_categorical_contains(self):
216216
self.key in self.c
217217

218218

219-
class CategoricalSlicing(object):
219+
class CategoricalSlicing:
220220

221221
params = ['monotonic_incr', 'monotonic_decr', 'non_monotonic']
222222
param_names = ['index']
@@ -257,7 +257,7 @@ def time_getitem_bool_array(self, index):
257257
self.data[self.data == self.cat_scalar]
258258

259259

260-
class Indexing(object):
260+
class Indexing:
261261

262262
def setup(self):
263263
N = 10**5

asv_bench/benchmarks/ctors.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def list_of_lists_with_none(arr):
3939
return [[i, -i] for i in arr][:-1] + [None]
4040

4141

42-
class SeriesConstructors(object):
42+
class SeriesConstructors:
4343

4444
param_names = ["data_fmt", "with_index", "dtype"]
4545
params = [[no_change,
@@ -68,7 +68,7 @@ def time_series_constructor(self, data_fmt, with_index, dtype):
6868
Series(self.data, index=self.index)
6969

7070

71-
class SeriesDtypesConstructors(object):
71+
class SeriesDtypesConstructors:
7272

7373
def setup(self):
7474
N = 10**4
@@ -90,7 +90,7 @@ def time_dtindex_from_index_with_series(self):
9090
Index(self.s)
9191

9292

93-
class MultiIndexConstructor(object):
93+
class MultiIndexConstructor:
9494

9595
def setup(self):
9696
N = 10**4

asv_bench/benchmarks/dtypes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
_dtypes = _numpy_dtypes + extension_dtypes
1313

1414

15-
class Dtypes(object):
15+
class Dtypes:
1616
params = (_dtypes +
1717
list(map(lambda dt: dt.name, _dtypes)))
1818
param_names = ['dtype']
@@ -21,7 +21,7 @@ def time_pandas_dtype(self, dtype):
2121
pandas_dtype(dtype)
2222

2323

24-
class DtypesInvalid(object):
24+
class DtypesInvalid:
2525
param_names = ['dtype']
2626
params = ['scalar-string', 'scalar-int', 'list-string', 'array-string']
2727
data_dict = {'scalar-string': 'foo',

0 commit comments

Comments
 (0)