Skip to content

Commit

Permalink
Set np printoptions (#32539)
Browse files Browse the repository at this point in the history
  • Loading branch information
Abacn authored Sep 23, 2024
1 parent 878ccce commit 65b2936
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion sdks/python/apache_beam/dataframe/doctests.py
Original file line number Diff line number Diff line change
Expand Up @@ -665,7 +665,10 @@ def set_pandas_options():
# See
# https://github.com/pandas-dev/pandas/blob/a00202d12d399662b8045a8dd3fdac04f18e1e55/doc/source/conf.py#L319
np.random.seed(123456)
np.set_printoptions(precision=4, suppress=True)
legacy = None
if np.version.version.startswith('2'):
legacy = '1.25'
np.set_printoptions(precision=4, suppress=True, legacy=legacy)
pd.options.display.max_rows = 15


Expand Down

0 comments on commit 65b2936

Please sign in to comment.