Skip to content
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

progress_map on panda's index #1557

Open
5 of 6 tasks
masalha-alaa opened this issue Mar 1, 2024 · 0 comments
Open
5 of 6 tasks

progress_map on panda's index #1557

masalha-alaa opened this issue Mar 1, 2024 · 0 comments

Comments

@masalha-alaa
Copy link

masalha-alaa commented Mar 1, 2024

  • I have marked all applicable categories:
    • documentation request (i.e. "X is missing from the documentation." If instead I want to ask "how to use X?" I understand StackOverflow#tqdm is more appropriate)
    • new feature request
  • I have visited the source website, and in particular
    read the known issues
  • I have searched through the issue tracker for duplicates
  • I have mentioned version numbers, operating system and
    environment, where applicable:
    import tqdm, sys
    print(tqdm.__version__, sys.version, sys.platform)
    # 4.66.2 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0] linux

Issue:
progress_map on pandas index is not supported:

from tqdm.auto import tqdm
tqdm.pandas()

import pandas as pd

df = pd.DataFrame(data=list(range(5)), columns=['x'])
df['x'].progress_map(lambda x: x**2)  # => works and shows progress bar
df.index.map(lambda x: x**2)  # => prints index values squared
df.index.progress_map(lambda x: x**2)  # => error: AttributeError: 'RangeIndex' object has no attribute 'progress_map'

Expected behavior (feature request):
df.index.progress_map should show progress bar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant