Skip to content

Add a large scale illumination effect #898

Merged
oczoske merged 6 commits intoAstarVienna:mainfrom
ShannonS00:shs/illumination
Apr 15, 2026
Merged

Add a large scale illumination effect #898
oczoske merged 6 commits intoAstarVienna:mainfrom
ShannonS00:shs/illumination

Conversation

@ShannonS00
Copy link
Copy Markdown
Contributor

  • New effect in effects/illumination.py that applies large-scale illumination variation (e.g. vignetting) to the image plane

2 Build in callable models:

  1. _gaussian2d (normalised 2D elliptical Gaussian)
  2. poly_vignetting (asymmetric polynomial with direct falloff control).
  • Own model input possible
    Example:

    def my_model(xx, yy, slope=-0.001):
           return np.clip(1 + slope * np.sqrt(xx**2 + yy**2), 0, None)
    
       eff = Illumination(model=my_model, modelargs={"slope": -0.0005})
    
  • can be included via !DET.include_illumination

Included Tests in scopesim/tests/tests_effects/test_illumination.py

…D elliptical Gaussian.

, 2. Asymmetric polynomial vignetting with direct falloff control.
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 2, 2026

Codecov Report

❌ Patch coverage is 86.66667% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 75.19%. Comparing base (db7a81b) to head (6212521).
⚠️ Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
scopesim/effects/illumination.py 86.44% 8 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #898      +/-   ##
==========================================
+ Coverage   75.11%   75.19%   +0.07%     
==========================================
  Files          69       70       +1     
  Lines        8953     9013      +60     
==========================================
+ Hits         6725     6777      +52     
- Misses       2228     2236       +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@teutoburg teutoburg moved this to 🏗 In progress in ScopeSim-development Apr 2, 2026
@oczoske oczoske linked an issue Apr 3, 2026 that may be closed by this pull request
Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
Copy link
Copy Markdown
Collaborator

@oczoske oczoske left a comment

Choose a reason for hiding this comment

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

Just one request about theta, otherwise that looks fine.

Copy link
Copy Markdown
Collaborator

@oczoske oczoske left a comment

Choose a reason for hiding this comment

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

Almost there...

Comment thread scopesim/effects/illumination.py Outdated
Comment thread scopesim/effects/illumination.py Outdated
@oczoske oczoske marked this pull request as ready for review April 15, 2026 17:57
@oczoske oczoske self-requested a review April 15, 2026 17:58
@oczoske oczoske merged commit 07a7031 into AstarVienna:main Apr 15, 2026
26 checks passed
@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in ScopeSim-development Apr 15, 2026
@teutoburg teutoburg added enhancement PR adding or improving a feature (use "Feature" type for issues (requests), not this label) effects Related to a ScopeSim effect Pipeline dev. Technical target audience labels Apr 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effects Related to a ScopeSim effect enhancement PR adding or improving a feature (use "Feature" type for issues (requests), not this label) Pipeline dev. Technical target audience

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

Add large scale Illumination effect / Vignetting

3 participants