Modular form computation Error messages

asked 2024-04-02 05:18:01 +0200

byoungdu.kim gravatar image

updated 2024-04-15 07:49:55 +0200

FrédéricC gravatar image

Me and my colleague ran the following computation:

B=CuspForms(7*1381).q_integral_basis(prec=750)
X1=DirichletGroup(7*1381).1
X=X1^345
h=ModularForms(X^(-1),1).eisenstein_subspace().q_expansion_basis(prec=750)

This ran fine for a different level (for the level 4x1381 or 8x1381), but this time, we got a really long error message. It's too long to post here, but the gist of it is two parts.

  1. The first part is made up of something like:

    During handling of the above exception, another exception occurred:

    KeyError Traceback (most recent call last) File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:986, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5775)() 985 try: --> 986 return self.cache[k] 987 except TypeError: # k is not hashable

    KeyError: ((Dirichlet character modulo 9667 of conductor 1381 mapping 1382 |--> 1, 4145 |--> -zeta4, 2), ())

And, the message goes on like this for a few more times, and then

  1. The second part of the error message (and this is a bit longer) is made up of things like:

    During handling of the above exception, another exception occurred:

    PariError Traceback (most recent call last) Cell In[18], line 1 ----> 1 h=ModularForms(X**(-Integer(1)),Integer(1)).eisenstein_subspace().q_expansion_basis(prec=Integer(750))[Integer(0)];

    File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/constructor.py:352, in ModularForms(group, weight, base_ring, eis_only, use_cache, prec) 348 if eps.is_trivial(): 349 return ModularForms(eps.modulus(), weight, base_ring, 350 use_cache=use_cache, 351 prec=prec) --> 352 M = ModularFormsAmbient_eps(eps, weight, eis_only=eis_only) 353 if base_ring != eps.base_ring(): 354 M = M.base_extend(base_ring) # ambient_R.ModularFormsAmbient_R(M, base_ring)

The error message is really long, so I will copy and paste it below.

We've been trying to understand the meaning of this, but have failed so far. Also, it really puzzles us that the same computation worked fine for a different number.

Does anyone know what these messages mean?

Below is the full error message:


KeyError Traceback (most recent call last) File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:986, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5775)() 985 try: --> 986 return self.cache[k] 987 except TypeError: # k is not hashable

KeyError: ((Dirichlet character modulo 9667 of conductor 1381 mapping 1382 |--> 1, 4145 |--> -zeta4,), ())

During handling of the above exception, another exception occurred:

KeyError Traceback (most recent call last) File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:986, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5775)() 985 try: --> 986 return self.cache[k] 987 except TypeError: # k is not hashable

KeyError: ((Dirichlet character modulo 9667 of conductor 1381 mapping 1382 |--> 1, 4145 |--> -zeta4, 2), ())

During handling of the above exception, another exception occurred:

KeyError Traceback (most recent call last) File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:986, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5775)() 985 try: --> 986 return self.cache[k] 987 except TypeError: # k is not hashable

KeyError: ((Dirichlet character modulo 9667 of conductor 1381 mapping 1382 |--> 1, 4145 |--> -zeta4,), ())

During handling of the above exception, another exception occurred:

PariError Traceback (most recent call last) Cell In[18], line 1 ----> 1 h=ModularForms(X**(-Integer(1)),Integer(1)).eisenstein_subspace().q_expansion_basis(prec=Integer(750))[Integer(0)];

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/constructor.py:352, in ModularForms(group, weight, base_ring, eis_only, use_cache, prec) 348 if eps.is_trivial(): 349 return ModularForms(eps.modulus(), weight, base_ring, 350 use_cache=use_cache, 351 prec=prec) --> 352 M = ModularFormsAmbient_eps(eps, weight, eis_only=eis_only) 353 if base_ring != eps.base_ring(): 354 M = M.base_extend(base_ring) # ambient_R.ModularFormsAmbient_R(M, base_ring)

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/ambient_eps.py:130, in ModularFormsAmbient_eps.__init__(self, character, weight, base_ring, eis_only) 128 group = arithgroup.Gamma1(character.modulus()) 129 base_ring = character.base_ring() --> 130 ModularFormsAmbient.__init__(self, group, weight, base_ring, character, eis_only)

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/ambient.py:117, in ModularFormsAmbient.__init__(self, group, weight, base_ring, character, eis_only) 115 d = self._dim_eisenstein() 116 else: --> 117 d = self.dimension() 118 AmbientHeckeModule.__init__(self, base_ring, d, group.level(), weight)

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:2300, in sage.misc.cachefunc.CachedMethodCallerNoArgs.__call__ (build/cythonized/sage/misc/cachefunc.c:12734)() 2298 if self.cache is None: 2299 f = self.f -> 2300 self.cache = f(self._instance) 2301 return self.cache 2302

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/ambient.py:206, in ModularFormsAmbient.dimension(self) 193 @cached_method 194 def dimension(self): 195 """ 196 Return the dimension of this ambient space of modular forms, 197 computed using a dimension formula (so it should be reasonably (...) 204 238 205 """ --> 206 return self._dim_eisenstein() + self._dim_cuspidal()

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:2300, in sage.misc.cachefunc.CachedMethodCallerNoArgs.__call__ (build/cythonized/sage/misc/cachefunc.c:12734)() 2298 if self.cache is None: 2299 f = self.f -> 2300 self.cache = f(self._instance) 2301 return self.cache 2302

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/ambient.py:587, in ModularFormsAmbient._dim_cuspidal(self) 585 return 0 586 if is_Gamma1(self.group()) and self.character() is not None: --> 587 return self.group().dimension_cusp_forms(self.weight(), 588 self.character()) 589 else: 590 return self.group().dimension_cusp_forms(self.weight())

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/arithgroup/congroup_gamma1.py:466, in Gamma1_class.dimension_cusp_forms(self, k, eps, algorithm) 464 if k == 1: 465 from sage.modular.modform.weight1 import dimension_wt1_cusp_forms --> 466 return dimension_wt1_cusp_forms(eps) 468 # now the main part 470 if algorithm == "Quer":

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:991, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5903)() 989 return self.cache[k] 990 except KeyError: --> 991 w = self.f(args, *kwds) 992 self.cache[k] = w 993 return w

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/weight1.py:200, in dimension_wt1_cusp_forms(chi) 189 @cached_function 190 def dimension_wt1_cusp_forms(chi): 191 r""" 192 Return the dimension of the space of cusp forms of weight 1 and character chi. 193 (...) 198 1 199 """ --> 200 return len(hecke_stable_subspace(chi))

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:991, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5903)() 989 return self.cache[k] 990 except KeyError: --> 991 w = self.f(args, *kwds) 992 self.cache[k] = w 993 return w

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/weight1.py:144, in hecke_stable_subspace(chi, aux_prime) 141 R = l*Gamma0(N).sturm_bound(l + 2) 143 t = verbose("Computing modular ratio space", level=1) --> 144 mrs = modular_ratio_space(chi) 146 t = verbose("Computing modular ratios to precision %s" % R, level=1) 147 qexps = [modular_ratio_to_prec(chi, f, R) for f in mrs]

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/misc/cachefunc.pyx:991, in sage.misc.cachefunc.CachedFunction.__call__ (build/cythonized/sage/misc/cachefunc.c:5903)() 989 return self.cache[k] 990 except KeyError: --> 991 w = self.f(args, *kwds) 992 self.cache[k] = w 993 return w

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modular/modform/weight1.py:67, in modular_ratio_space(chi) 65 quots = (c/b for c in C) 66 W = V.span(V(x.padded_list(R)) for x in quots) ---> 67 I = I.intersection(W) 68 if I.rank() < d: 69 verbose(" Cut down to dimension %s" % I.rank(), level=1)

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/modules/free_module.py:4537, in FreeModule_generic_field.intersection(self, other) 4535 A2 = V2.basis_matrix() 4536 S = A1.stack(A2) -> 4537 K = S.kernel() 4538 n = int(V1.dimension()) 4539 B = [A1.linear_combination_of_rows(v.list()[:n]) for v in K.basis()]

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/matrix/matrix2.pyx:5094, in sage.matrix.matrix2.Matrix.left_kernel (build/cythonized/sage/matrix/matrix2.c:34308)() 5092 5093 tm = verbose("computing left kernel for %sx%s matrix" % (self.nrows(), self.ncols()),level=1) -> 5094 K = self.transpose().right_kernel(args, *kwds) 5095 self.cache('left_kernel', K) 5096 verbose("done computing left kernel for %sx%s matrix" % (self.nrows(), self.ncols()),level=1,t=tm)

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/matrix/matrix2.pyx:4933, in sage.matrix.matrix2.Matrix.right_kernel (build/cythonized/sage/matrix/matrix2.c:33775)() 4931 4932 # Go get the kernel matrix, this is where it all happens -> 4933 M = self.right_kernel_matrix(*args, kwds) 4934 4935 ambient = Rself.ncols()

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/matrix/matrix2.pyx:4519, in sage.matrix.matrix2.Matrix.right_kernel_matrix (build/cythonized/sage/matrix/matrix2.c:32394)() 4517 4518 if M is None and isinstance(R, NumberField): -> 4519 format, M = self._right_kernel_matrix_over_number_field() 4520 4521 if M is None and R in _Fields:

File ~/mambaforge/envs/sage/lib/python3.10/site-packages/sage/matrix/matrix2.pyx:3727, in sage.matrix.matrix2.Matrix._right_kernel_matrix_over_number_field (build/cythonized/sage/matrix/matrix2.c:28733)() 3725 from sage.matrix.matrix_space import MatrixSpace 3726 tm = verbose("computing right kernel matrix over a number field for %sx%s matrix" % (self.nrows(), self.ncols()),level=1) -> 3727 basis = self.__pari__().matker() 3728 # Coerce PARI representations into the number field 3729 R = self.base_ring()

File cypari2/auto_gen.pxi:19454, in cypari2.gen.Gen_base.matker()

File cypari2/handle_error.pyx:213, in cypari2.handle_error._pari_err_handle()

PariError: the PARI stack overflows (current size: 1073741824; maximum size: 1073741824) You can use pari.allocatemem() to change the stack size and try again

B1=[_/h for _ in B];

B2=[hecke_operat

edit retag flag offensive close merge delete

Comments

which version of sage ?

FrédéricC gravatar imageFrédéricC ( 2024-04-02 12:22:53 +0200 )edit

It will help if you can dump the error message somewhere e.g. pastebin.

grhkm gravatar imagegrhkm ( 2024-04-03 03:37:20 +0200 )edit

We seem to be using Sage 9.6

And, I copied and pasted the entire error message. It seems I don't have enough points to upload a file.

byoungdu.kim gravatar imagebyoungdu.kim ( 2024-04-04 00:50:35 +0200 )edit

Relevant quote: PariError: the PARI stack overflows (current size: 1073741824; maximum size: 1073741824) You can use pari.allocatemem() to change the stack size and try again

rburing gravatar imagerburing ( 2024-04-04 10:05:40 +0200 )edit