René's URL Explorer Experiment


Title: R23-T054: Add ELU edge-value and SELU/Leaky ReLU agreement doctests by code-paul-creator · Pull Request #64 · S-AI-Projects/TheAlgorithms-Python · GitHub

Open Graph Title: R23-T054: Add ELU edge-value and SELU/Leaky ReLU agreement doctests by code-paul-creator · Pull Request #64 · S-AI-Projects/TheAlgorithms-Python

X Title: R23-T054: Add ELU edge-value and SELU/Leaky ReLU agreement doctests by code-paul-creator · Pull Request #64 · S-AI-Projects/TheAlgorithms-Python

Description: Description Compares exponential_linear_unit.py with scaled_exponential_linear_unit.py and leaky_rectified_linear_unit.py (API, numeric agreement, edge values, speed) and adds doctests to ELU that pin down the results: edge values, agreement with SELU at scale 1 and at SELU's documented constants, and agreement with Leaky ReLU on positive inputs. Related Issue Fixes: #54 Type of Change Bug Fix New Feature UI/UX Improvement Performance Improvement Tests Documentation Refactoring / Maintenance CI/CD Changes Made Added doctests to exponential_linear_unit for 0, large negative (-1000 saturates at -alpha), alpha=0, ELU == SELU(lambda_=1), SELU defaults == 1.0507 * ELU(x, 1.6732), and ELU == Leaky ReLU for positive inputs (existing 2 doctests unchanged; 13 total). Added work/R23-T054/compare_test.py (19 checks over 14 shared inputs and 5 alphas), bench_compare.py, and COMPARE.md (API differences, results, edge values, speed, beginner recommendation). Screenshots / Recordings Not applicable (no UI changes). Testing python -m pytest --doctest-modules neural_network/activation_functions/exponential_linear_unit.py -> passed (13 doctests) python -m pytest work/R23-T054/compare_test.py -> 19 passed ruff check neural_network/activation_functions/exponential_linear_unit.py -> all checks passed Checklist I have tested my changes locally. I have added or updated tests, if needed. I have updated documentation, if needed. I have followed the project's coding guidelines. I have run the relevant tests and checks. I have addressed previous review feedback, if applicable. Additional Notes Findings: ELU == SELU exactly when lambda_=1; ELU == Leaky ReLU on all positive inputs; all three give 0 at 0; they differ on negatives (ELU saturates at -alpha, Leaky ReLU is unbounded). A large positive input (e.g. 1000) returns the right value but emits RuntimeWarning: overflow encountered in exp in ELU/SELU because np.where evaluates both branches; not changed here. Details in work/R23-T054/COMPARE.md.

Open Graph Description: Description Compares exponential_linear_unit.py with scaled_exponential_linear_unit.py and leaky_rectified_linear_unit.py (API, numeric agreement, edge values, speed) and adds doctests to ELU that ...

X Description: Description Compares exponential_linear_unit.py with scaled_exponential_linear_unit.py and leaky_rectified_linear_unit.py (API, numeric agreement, edge values, speed) and adds doctests to ELU that ...

Opengraph URL: https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:723ec364-82ea-a635-76aa-7a3f0a0b828c
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idC47A:35F933:7C146:B53E6:6AFDCB1F
html-safe-nonce533edee798daa8c2b6bae2adfb5db5e1e0344f6edf5d027cc70a85b1f413fbfe
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNDdBOjM1RjkzMzo3QzE0NjpCNTNFNjo2QUZEQ0IxRiIsInZpc2l0b3JfaWQiOiI2MDUwMjkwMTYwNzQwNzE1Mjk1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacd9bcabde259a50dce858529b1cfac9374b05f6e55bc7f91a5bfca43a926243a7
hovercard-subject-tagpull_request:5254351261
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
twitter:imagehttps://avatars.githubusercontent.com/u/260575160?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/260575160?s=400&v=4
og:image:altDescription Compares exponential_linear_unit.py with scaled_exponential_linear_unit.py and leaky_rectified_linear_unit.py (API, numeric agreement, edge values, speed) and adds doctests to ELU that ...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None9ab00cc3b4fa90bbd3da70765dd38efc23cfa9d9b0930e41feea2bf67f60ecaf
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/S-AI-Projects/TheAlgorithms-Python git https://github.com/S-AI-Projects/TheAlgorithms-Python.git
octolytics-dimension-user_id351892385
octolytics-dimension-user_loginS-AI-Projects
octolytics-dimension-repository_id1444141022
octolytics-dimension-repository_nwoS-AI-Projects/TheAlgorithms-Python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forktrue
octolytics-dimension-repository_parent_id63476337
octolytics-dimension-repository_parent_nwoTheAlgorithms/Python
octolytics-dimension-repository_network_root_id63476337
octolytics-dimension-repository_network_root_nwoTheAlgorithms/Python
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release1b795ba060b92691fc16c5a12cf2bf95e83432b4
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FS-AI-Projects%2FTheAlgorithms-Python%2Fpull%2F64%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2FS-AI-Projects%2FTheAlgorithms-Python%2Fpull%2F64%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=S-AI-Projects%2FTheAlgorithms-Python
Reloadhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
Reloadhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
Reloadhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
S-AI-Projectshttps://github.com/S-AI-Projects
TheAlgorithms-Pythonhttps://github.com/S-AI-Projects/TheAlgorithms-Python
Codehttps://github.com/S-AI-Projects/TheAlgorithms-Python
Issues60 (60)https://github.com/S-AI-Projects/TheAlgorithms-Python/issues
Pull requests39 (39)https://github.com/S-AI-Projects/TheAlgorithms-Python/pulls
Actionshttps://github.com/S-AI-Projects/TheAlgorithms-Python/actions
Projectshttps://github.com/S-AI-Projects/TheAlgorithms-Python/projects
Security and qualityhttps://github.com/S-AI-Projects/TheAlgorithms-Python/security
Insightshttps://github.com/S-AI-Projects/TheAlgorithms-Python/insights
Sign up for GitHub https://github.com/signup?return_to=%2FS-AI-Projects%2FTheAlgorithms-Python%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2FS-AI-Projects%2FTheAlgorithms-Python%2Fissues%2Fnew%2Fchoose
code-paul-creatorhttps://github.com/code-paul-creator
S-AI-Projects:masterhttps://github.com/S-AI-Projects/TheAlgorithms-Python/tree/master
code-paul-creator:R23-T054https://github.com/code-paul-creator/TheAlgorithms-Python/tree/R23-T054
Conversation 0 https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64
Commits 1 https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/commits
Checks 0 https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/checks
Files changed https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
Please reload this pagehttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
R23-T054: Add ELU edge-value and SELU/Leaky ReLU agreement doctests https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#top
Show all changes 1 commit https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
334a2c4 R23-T054: add ELU edge-value and SELU/Leaky ReLU agreement doctests code-paul-creator Nov 11, 2026 https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/commits/334a2c49f4775a8f964516098a05f93d2e8acbd2
Clear filters https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
Please reload this pagehttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
Please reload this pagehttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files
exponential_linear_unit.py https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-aacd53d236c1eaf3096cbac4f18547fbbe4674378f8bbc2a0c633c17ef235cfb
COMPARE.md https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-37c9c57151a7eed3075355c60e572a123c4812b6398df5fb2ad14b575a43a6d7
bench_compare.py https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-eb87c490cb6b16ed6615baaa636cbeec4cc8e83106ed9ca1313e88d59184e26f
compare_test.py https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-4cf9c26930b57627193a0fde39d3e71faa704a1f9ab11b7272c7477b2717d842
neural_network/activation_functions/exponential_linear_unit.pyhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-aacd53d236c1eaf3096cbac4f18547fbbe4674378f8bbc2a0c633c17ef235cfb
View file https://github.com/S-AI-Projects/TheAlgorithms-Python/blob/334a2c49f4775a8f964516098a05f93d2e8acbd2/neural_network/activation_functions/exponential_linear_unit.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/{{ revealButtonHref }}
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-aacd53d236c1eaf3096cbac4f18547fbbe4674378f8bbc2a0c633c17ef235cfb
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-aacd53d236c1eaf3096cbac4f18547fbbe4674378f8bbc2a0c633c17ef235cfb
work/R23-T054/COMPARE.mdhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-37c9c57151a7eed3075355c60e572a123c4812b6398df5fb2ad14b575a43a6d7
View file https://github.com/S-AI-Projects/TheAlgorithms-Python/blob/334a2c49f4775a8f964516098a05f93d2e8acbd2/work/R23-T054/COMPARE.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/{{ revealButtonHref }}
work/R23-T054/bench_compare.pyhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-eb87c490cb6b16ed6615baaa636cbeec4cc8e83106ed9ca1313e88d59184e26f
View file https://github.com/S-AI-Projects/TheAlgorithms-Python/blob/334a2c49f4775a8f964516098a05f93d2e8acbd2/work/R23-T054/bench_compare.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/{{ revealButtonHref }}
work/R23-T054/compare_test.pyhttps://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/files#diff-4cf9c26930b57627193a0fde39d3e71faa704a1f9ab11b7272c7477b2717d842
View file https://github.com/S-AI-Projects/TheAlgorithms-Python/blob/334a2c49f4775a8f964516098a05f93d2e8acbd2/work/R23-T054/compare_test.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/S-AI-Projects/TheAlgorithms-Python/pull/64/{{ revealButtonHref }}
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.