-
Notifications
You must be signed in to change notification settings - Fork 2
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
Fix: try to improve the visibility criteria #165
Conversation
Also compute the dot product between disc normal and velocity when trying to ascertain whether a point on the disc is visible or not. Caution against using just the projected radius, as this is biases towards visibility when the disc is steeply inclined. Prefer checking the Cartesian distance instead.
…oint for interpolation
Codecov ReportPatch coverage:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #165 +/- ##
==========================================
+ Coverage 69.15% 69.27% +0.12%
==========================================
Files 66 66
Lines 2707 2734 +27
==========================================
+ Hits 1872 1894 +22
- Misses 835 840 +5
☔ View full report in Codecov by Sentry. |
Straight out of the old catechism. Soon as one gives up all hope: providence. The Jacobian function wasn't being given the thick disc, and was calculating the Jacobian over the datum plane instead. It's amazing that that actually makes a difference when you consider what's going on, but yeah. Wow. |
Basically, the conclusion of investigating #160 is that the root finder thinks it can see emission radii that are actually obscured. It's amazing just how big of an impact this really has, but tweaking the old visibility tolerance parameter helped the two curves line up in places. So it's clear we need a better visibility criteria: the question is just what?
I tried to make the
_is_visible
function more robust in this PR. Instead of just checking the proximity of a trajectory, traced with the full thick disc, to the target emission radius (which is biased towards concluding visible at small radii), the first simple change is to check the Cartesian distance between the target point and the geodesic endpoint.This isn't however always enough, and requires recomputing the geodesic too (which should be treated at the$< \epsilon$ level as probabilistic). Another method that I have tried is to compute the vector normal to the surface of the disc via automatic differentiation, and then check if the velocity vector at the endpoint of the geodesic, $\vec{v}$ , satisfies
as a visibility critera. Since both tangent vectors belong to the same space of forms in the Kerr spacetime, the tangent space can be treated as locally Euclidean (Minkowski), and therefore this is equivalent to asking whether the geodesic came from behind the disc or not.
However, neither of these two things (seperately or in tandem) are enough to correct the lineprofile differences. The state is slightly improved, and by tweaking tolerances once can more or less force the line profiles to become very similar, albeit noisy, just as before.
This introduces a slightly metaphysical question however: if we regard the transfer funciton method as equivalent to an image with infinite resolution, then it will be able to see small patches of the disc that our finite resolution render will not. Are these emissions physical? Should these flux contributions be included, and the binning method disregarded as unable to appropriately evaluate in the limit of infinite resolution? Or do we conclude that the transfer function method is giving too much weight to portions of the disc that would lend miniscule contributions to the overall flux profile?
I am still unable to decide which of the two methods is "correct". And although we have discovered the bug, it is unsatisfying that an improved visibility criteria is unable to improve the lineprofiles unless the visibility criteria lends myopia to the method. It's kind of like saying "yes, the transfer function method agrees, but only if you or the algorithm squint".