-
Notifications
You must be signed in to change notification settings - Fork 126
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
Check for unnecessary uses of underlying_scheme #2584
Comments
@StevellM Thank you for adressing the problem immediately. |
@benlorenz I asked Stevell to put in the docstring of the show methods so that it is tested by our CI. Which apparently helped to find this bug. Do you see a better way to test that all the printing works as intended? |
I think the problem is that by default a call to `base_ring` first realizes the full `underlying_scheme`. Indeed, an easier workaround should be to add `base_ring(X::EllipticSurface) = coefficient_ring(base_field(elliptic_curve(X)))` or something similar, i.e. to infer the base ring from the elliptic curve for `X`.
…On July 25, 2023 8:35:47 AM GMT+01:00, simonbrandhorst ***@***.***> wrote:
@benlorenz I asked Stevell to put in the docstring of the show methods so that it is tested by our CI. Which apparently helped to find this bug. Do you see a better way to test that all the printing works as intended?
--
Reply to this email directly or view it on GitHub:
#2584 (comment)
You are receiving this because you were mentioned.
Message ID: ***@***.***>
|
Anne wanted to reopen this... |
Anne @afkafkafk13 is analysing and managing this further... |
@afkafkafk13 In this special case the reason is that |
For this occurrence of the problem, I fully agree with you.
|
Regarding how to test the printing, there are multiple options:
|
Describe the bug
The show method for EllipticSurface can be extremely slow:
Oscar.jl/experimental/Schemes/elliptic_surface.jl
Lines 238 to 269 in b7b63dc
To Reproduce
Run the code from the doctest in
elliptic_surface.jl:241-253
:The last step takes about 200 seconds including compilation time. After recreating the object it takes "only" about 60 seconds (i.e. excluding compilation time)
More precisely it happens due to
show
callingbase_ring
:Expected behavior
If this method can take that long it should not be used in the show method and maybe not in the doctests as well. Maybe there is an easier / faster way to determine the base_ring ?
Also I don't think it is a good idea to attach an example to the docstring of
Base.show
, I can't find it in our documentation.This was added in #2580, cc: @StevellM
The text was updated successfully, but these errors were encountered: