Live
Black Hat USADark ReadingBlack Hat AsiaAI BusinessCrack ML Interviews with Confidence: ML Model Development (20 Q&A)Towards AICoreWeave Stock Analysis: Buy or Sell This Nvidia-Backed AI Stock? - The Motley FoolGNews AI NVIDIAIntel Arc B70 Benchmarks/Comparison to Nvidia RTX 4070 SuperReddit r/LocalLLaMAI Gave Claude Access to My Desktop Outlook Without Touching the Microsoft APITowards AIBanning All Anthropic EmployeesHacker NewsMicrosoft is automatically updating Windows 11 24H2 to 25H2 using machine learning - TweakTownGoogle News: Machine Learning80 Years to an Overnight Success: The Real History of Artificial Intelligence - Futurist SpeakerGoogle News: AIGoogle’s Gemma 4 Tied Qwen 3.5 on Benchmarks. Then Won on One Word: Apache.Towards AIWhat next for the struggling rural mothers in China who helped to build AI?SCMP Tech (Asia AI)Apple reportedly signed a 3rd-party driver, by Tiny Corp, for AMD or Nvidia eGPUs for Apple Silicon Macs; it s meant for AI research, not accelerating graphics (AppleInsider)TechmemeBest Resume Builders in 2026: I Applied to 50 Jobs to Test TheseDEV CommunityTruth Technology and the Architecture of Digital TrustDEV CommunityBlack Hat USADark ReadingBlack Hat AsiaAI BusinessCrack ML Interviews with Confidence: ML Model Development (20 Q&A)Towards AICoreWeave Stock Analysis: Buy or Sell This Nvidia-Backed AI Stock? - The Motley FoolGNews AI NVIDIAIntel Arc B70 Benchmarks/Comparison to Nvidia RTX 4070 SuperReddit r/LocalLLaMAI Gave Claude Access to My Desktop Outlook Without Touching the Microsoft APITowards AIBanning All Anthropic EmployeesHacker NewsMicrosoft is automatically updating Windows 11 24H2 to 25H2 using machine learning - TweakTownGoogle News: Machine Learning80 Years to an Overnight Success: The Real History of Artificial Intelligence - Futurist SpeakerGoogle News: AIGoogle’s Gemma 4 Tied Qwen 3.5 on Benchmarks. Then Won on One Word: Apache.Towards AIWhat next for the struggling rural mothers in China who helped to build AI?SCMP Tech (Asia AI)Apple reportedly signed a 3rd-party driver, by Tiny Corp, for AMD or Nvidia eGPUs for Apple Silicon Macs; it s meant for AI research, not accelerating graphics (AppleInsider)TechmemeBest Resume Builders in 2026: I Applied to 50 Jobs to Test TheseDEV CommunityTruth Technology and the Architecture of Digital TrustDEV Community
AI NEWS HUBbyEIGENVECTOREigenvector

trunk/3c9726cdf76b01c44fac8473c2f3d6d11249099e: Replace erase idiom for map/set with erase_if (#179373)

PyTorch Releasesby lakshaygApril 4, 20261 min read0 views
Source Quiz

C++20 provides std::erase_if(container, pred) which is equivalent to the following much longer code snippet for associative containers: auto it = container.begin(); while (it != container.end()) { if ( pred (*it)) { it = container. erase (it); } else { ++it; } } PyTorch now supports C++20: #176662 Pull Request resolved: #179373 Approved by: https://github.com/cyyever , https://github.com/Skylion007

C++20 provides std::erase_if(container, pred) which is equivalent to the following much longer code snippet for associative containers:

cpp
auto it = container.begin();
while (it != container.end()) {
 if (pred(*it)) {
 it = container.erase(it);
 } else {
 ++it;
 }
}

PyTorch now supports C++20: #176662 Pull Request resolved: https://github.com/pytorch/pytorch/pull/179373 Approved by: https://github.com/cyyever, https://github.com/Skylion007`

Assets 2

Was this article helpful?

Sign in to highlight and annotate this article

AI
Ask AI about this article
Powered by Eigenvector · full article context loaded
Ready

Conversation starters

Ask anything about this article…

Daily AI Digest

Get the top 5 AI stories delivered to your inbox every morning.

More about

github

Knowledge Map

Knowledge Map
TopicsEntitiesSource
trunk/3c972…githubPyTorch Rel…

Connected Articles — Knowledge Graph

This article is connected to other articles through shared AI topics and tags.

Knowledge Graph100 articles · 211 connections
Scroll to zoom · drag to pan · click to open

Discussion

Sign in to join the discussion

No comments yet — be the first to share your thoughts!

More in Products