Opened 8 months ago

Last modified 6 weeks ago

#32773 needs_review defect

Another test failure with KlyachkoBundle_class.random_deformation

Reported by: gh-kliem Owned by:
Priority: major Milestone: sage-9.7
Component: algebraic geometry Keywords:
Cc: vbraun, mjo, gh-collares Merged in:
Authors: Markus Wageringel Reviewers:
Report Upstream: N/A Work issues:
Branch: u/gh-mwageringel/32773 (Commits, GitHub, GitLab) Commit: 27c8891779b28bf0bf0da619889f8a57458827d4
Dependencies: Stopgaps:

Status badges

Description

Part of #32544:

Bug or incorrect test?

sage -t --long --random-seed=23747002002644886606785003174022326205 src/sage/schemes/toric/sheaf/klyachko.py
**********************************************************************
File "src/sage/schemes/toric/sheaf/klyachko.py", line 951, in sage.schemes.toric.sheaf.klyachko.KlyachkoBundle_class.random_deformation
Failed example:
    Vtilde.cohomology(dim=True, weight=(0,))
Expected:
    (1, 0)
Got:
    (0, 0)

Change History (12)

comment:1 Changed 7 months ago by dcoudert

Another one:

sage -t --long --warn-long 289.1 --random-seed=213487260798313884417459570000434714591 src/sage/schemes/toric/sheaf/klyachko.py
**********************************************************************
File "src/sage/schemes/toric/sheaf/klyachko.py", line 29, in sage.schemes.toric.sheaf.klyachko
Failed example:
    V.cohomology(dim=True, weight=(0,0,0,0))    # long time
Expected:
    (0, 0, 3, 0, 0)
Got:
    (0, 0, 0, 0, 0)

comment:2 Changed 6 months ago by mkoeppe

  • Milestone changed from sage-9.5 to sage-9.6

comment:3 Changed 6 months ago by mjo

  • Cc vbraun mjo added

comment:4 Changed 5 months ago by gh-mwageringel

The source of the problem seems to be the implementation of FilteredVectorSpace_class.random_deformation (source). This is the relevant code:

        filtration = dict()
        for deg, filt in self._filt[1:]:
            generators = [v + epsilon * random_vector(R, self.rank())
                          for v in filt.echelonized_basis()]
            filtration[deg] = generators

Occasionally, this random deformation results in generators that are linearly dependent, so that the new filtered component is of lower dimension than the original. It seems to me that this is not intended, as this will only happen in rare cases. Should we add a check here to avoid this?

Last edited 5 months ago by gh-mwageringel (previous) (diff)

comment:5 Changed 5 months ago by gh-mwageringel

  • Branch set to u/gh-mwageringel/32773
  • Commit set to 27c8891779b28bf0bf0da619889f8a57458827d4
  • Status changed from new to needs_review

Here is an attempt at a partial fix which I think respects the original intent, while preserving the subspace inclusions and dimensions of the filtered vector spaces.

This fixes the issue in the description, but the test from comment:1 still sometimes fails:

sage -t --long --warn-long 69.2 --random-seed=298280877953805287150486292027026647714 src/sage/schemes/toric/sheaf/klyachko.py
**********************************************************************
File "src/sage/schemes/toric/sheaf/klyachko.py", line 29, in sage.schemes.toric.sheaf.klyachko
Failed example:
    V.cohomology(dim=True, weight=(0,0,0,0))    # long time
Expected:
    (0, 0, 3, 0, 0)
Got:
    (0, 0, 5, 0, 0)

New commits:

27c889132773: preserve dimensions and subspace inclusions in deformations

comment:6 Changed 5 months ago by slelievre

  • Authors set to Markus Wageringel

comment:7 Changed 5 months ago by gh-mwageringel

If the current fix seems acceptable, I would suggest to open a new ticket for the remaining failure. We can mark it as known bug here to make the tests pass again.

comment:8 Changed 4 months ago by mjo

It looks like all of this machinery was added specifically for Klyachko bundles, so it really comes down to the intent. And I think the FilteredVectorSpace constructor guarantees the subspace inclusions? If so, it's only the dimensions of the components that can cause an issue; I don't see a problem with that a priori for general filtered vector spaces, but the docs for the Klyachko bundle method say,

Return a generic torus-equivariant deformation of the bundle... A new Klyachko bundle with randomly perturbed moduli. In particular, the same Chern classes.

and I have to admit that I don't know what very many of those words mean. If it's only the Klyachko class that needs the dimensions of the components to remain invariant, it might be better to change

while not filt.is_exhaustive():
    filt = self._filt.random_deformation(epsilon)

to preserve those dimensions as well.

comment:9 Changed 4 months ago by gh-mwageringel

Yes, I think your assessments are correct. I am not completely sure about the original intent either.

@vbraun: Could you help us on this, please? You seem to be the original author. In particular, what is needed for the random deformations of Klyachko bundles to have those properties? And should random deformations of filtered vector spaces preserve the dimensions of their components?

comment:10 Changed 3 months ago by dimpase

it seems to me that "random" here silently means "generic", as well.

comment:11 Changed 2 months ago by mkoeppe

  • Milestone changed from sage-9.6 to sage-9.7

comment:12 Changed 6 weeks ago by gh-collares

  • Cc gh-collares added
Note: See TracTickets for help on using tickets.