Skip to content

Commit

Permalink
Fix column axis rename in pandas 1.0 (#2886)
Browse files Browse the repository at this point in the history
* Fix column axis rename in pandas 1.0

Fix axis rename and unpin pandas
  • Loading branch information
dstrain115 committed Apr 6, 2020
1 parent 76b2689 commit 4320e52
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cirq/experiments/t1_decay_experiment.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def t1_decay(sampler: work.Sampler,

# Cross tabulate into a delay_ns, false_count, true_count table.
tab = pd.crosstab(results.delay_ns, results.output)
del tab.columns.name
tab.rename_axis(None, axis="columns", inplace=True)
tab = tab.rename(columns={0: 'false_count', 1: 'true_count'}).reset_index()
for col_index, name in [(1, 'false_count'), (2, 'true_count')]:
if name not in tab:
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ google-api-core[grpc] >= 1.14.0, < 2.0.0dev
matplotlib~=3.0
networkx~=2.4
numpy~=1.16
pandas~=0.25
pandas
protobuf==3.8.0
requests~=2.18
sortedcontainers~=2.0
Expand Down

0 comments on commit 4320e52

Please sign in to comment.