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

[Q] Fetch all projects and reports of a user #7703

Closed
SauravMaheshkar opened this issue May 25, 2024 · 6 comments
Closed

[Q] Fetch all projects and reports of a user #7703

SauravMaheshkar opened this issue May 25, 2024 · 6 comments

Comments

@SauravMaheshkar
Copy link

Is there any way in which I can fetch all the projects and all the reports of a particular user ?

@gsaltintas
Copy link

As per the documentation, you can use something like below:

entity = "ENTITY_NAME"
reports = [] 
for project in  api.projects(entity=entity):
    reports.extend(api.reports(path="/".join(project.path)))

@JoanaMarieL
Copy link

Thank you for sharing @gsaltintas , does this work for you @SauravMaheshkar ?

@SauravMaheshkar
Copy link
Author

Thank you @gsaltintas for the help. @JoanaMarieL I'm able to get all of my written reports using the above snippet. However it seems like each report is a instance of BetaReport. Is there any way I can access the blocks of each of these reports ? I remember there used to be a blocks attribute perhaps in a previous API version ?

@JoanaMarieL
Copy link

Hi @SauravMaheshkar , could you please try this block of code, to pull the list of reports:

api = wandb.Api()
reports = api.reports(path="<entity>/<project>")
for report in reports:
    print(report, report.displayName)

@JoanaMarieL
Copy link

Hi @SauravMaheshkar , since we have not heard back from you we are going to close this request. If you would like to re-open the conversation, please let us know!

@SauravMaheshkar
Copy link
Author

Hi @SauravMaheshkar , since we have not heard back from you we are going to close this request. If you would like to re-open the conversation, please let us know!

Yup, I've opened another issue in wandb/wandb-workspaces, that seems like a better place for this query.

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

3 participants