Skip to content

docs: add aggregate profiler memory example#4054

Merged
SunMarc merged 1 commit into
huggingface:mainfrom
aryanputta:aryan/profiler-memory-docs
Jun 9, 2026
Merged

docs: add aggregate profiler memory example#4054
SunMarc merged 1 commit into
huggingface:mainfrom
aryanputta:aryan/profiler-memory-docs

Conversation

@aryanputta

Copy link
Copy Markdown
Contributor

Summary

  • add a small aggregate-memory example to the profiler guide
  • show how to pair Accelerator.profile() with torch.cuda.reset_peak_memory_stats()
  • document a lightweight way to log peak allocated and reserved memory without adding a new manager API

Why

Issue #3300 asks for a memory logging manager, but the maintainer discussion suggests that a documented minimal example may already cover the main need for many users.

Testing

  • docs-only change
  • reviewed rendered markdown locally in diff form

Related

@SunMarc SunMarc left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks !

@HuggingFaceDocBuilderDev

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@SunMarc SunMarc merged commit a2e5292 into huggingface:main Jun 9, 2026
2 checks passed
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

Successfully merging this pull request may close these issues.

[Feature Request] add a memory logging manager

3 participants