diff --git a/lmfdb/classical_modular_forms/main.py b/lmfdb/classical_modular_forms/main.py index edba379353..bcd08f4fb1 100644 --- a/lmfdb/classical_modular_forms/main.py +++ b/lmfdb/classical_modular_forms/main.py @@ -182,8 +182,6 @@ def index(): return dimension_space_search(info) elif search_type == 'Traces': return trace_search(info) - elif search_type == 'SpaceTraces': - return space_trace_search(info) else: flash_error("Invalid search type; if you did not enter it in the URL please report") info["stats"] = CMF_stats() @@ -486,9 +484,9 @@ def mf_data(label): ocode = db.mf_newspaces.lookup(label, "hecke_orbit_code") if ocode is None: return abort(404, f"{label} not in database") - tables = ["mf_newspaces", "mf_subspaces", "mf_newspace_portraits", "mf_hecke_newspace_traces"] - labels = [label, label, label, ocode] - label_cols = ["label", "label", "label", "hecke_orbit_code"] + tables = ["mf_newspaces", "mf_newspace_portraits"] + labels = [label, label] + label_cols = ["label", "label"] title = f"Newspace data - {label}" elif len(slabel) == 2: tables = ["mf_gamma1", "mf_gamma1_portraits"] @@ -891,7 +889,7 @@ def newform_search(info, query): newform_parse(info, query) set_info_funcs(info) -def trace_postprocess(res, info, query, spaces=False): +def trace_postprocess(res, info, query): if res: if info.get('view_modp') == 'reductions': q = int(info['an_modulo']) @@ -899,7 +897,7 @@ def trace_postprocess(res, info, query, spaces=False): q = None hecke_codes = [mf['hecke_orbit_code'] for mf in res] trace_dict = defaultdict(dict) - table = db.mf_hecke_newspace_traces if spaces else db.mf_hecke_traces + table = db.mf_hecke_traces for rec in table.search({'n':{'$in': info['Tr_n']}, 'hecke_orbit_code':{'$in':hecke_codes}}, projection=['hecke_orbit_code', 'n', 'trace_an'], sort=[]): if q: trace_dict[rec['hecke_orbit_code']][rec['n']] = (rec['trace_an'] % q) @@ -962,22 +960,6 @@ def trace_search(info, query): process_an_constraints(info, query) set_info_funcs(info) -@search_wrap(template="cmf_space_trace_search_results.html", - table=db.mf_newspaces, - title='Newspace search results', - err_title='Newspace search input error', - shortcuts={'jump':jump_box, - 'download':CMF_download().download_multiple_space_traces}, - projection=['label', 'dim', 'hecke_orbit_code', 'weight'], - postprocess=space_trace_postprocess, - bread=get_search_bread, - learnmore=learnmore_list) -def space_trace_search(info, query): - set_Trn(info, query) - newspace_parse(info, query) - process_an_constraints(info, query) - set_info_funcs(info) - def set_rows_cols(info, query): """ Sets weight_list and level_list, which are the row and column headers @@ -1454,8 +1436,7 @@ class CMFSearchArray(SearchArray): _sort_forms = [(name, disp, sord + ['hecke_orbit']) for (name, disp, sord) in _sort] sorts = {'': _sort_forms, 'Traces': _sort_forms, - 'Spaces': _sort_spaces, - 'SpaceTraces': _sort_spaces} + 'Spaces': _sort_spaces} jump_example="3.6.a.a" jump_egspan="e.g. 3.6.a.a, 55.3.d or 20.5" jump_knowl="cmf.search_input" @@ -1746,7 +1727,7 @@ def main_array(self, info): if info is None: return self.browse_array search_type = info.get('search_type', info.get('hst', '')) - if search_type in ['Spaces', 'SpaceTraces']: + if search_type == 'Spaces': return self.space_array elif search_type == 'SpaceDimensions': return self.sd_array @@ -1761,7 +1742,6 @@ def search_types(self, info): ('Random', 'Random form')] spaces = [('Spaces', 'List of spaces'), ('SpaceDimensions', 'Dimension table'), - ('SpaceTraces', 'Traces table'), ('RandomSpace', 'Random')] if info is None: return basic @@ -1788,7 +1768,7 @@ def html(self, info=None): # We need to override html to add the trace inputs layout = [self.hidden_inputs(info), self.main_table(info), self.buttons(info)] st = self._st(info) - if st in ["Traces", "SpaceTraces"]: + if st in ["Traces"]: trace_table = self._print_table(self.traces_array, info, layout_type="box") layout.append(trace_table) return "\n".join(layout) diff --git a/lmfdb/classical_modular_forms/test_cmf.py b/lmfdb/classical_modular_forms/test_cmf.py index 2c0617fe31..93a77ab99f 100644 --- a/lmfdb/classical_modular_forms/test_cmf.py +++ b/lmfdb/classical_modular_forms/test_cmf.py @@ -554,9 +554,7 @@ def test_underlying_data(self): data = self.tc.get('/ModularForm/GL2/Q/holomorphic/data/13.2.e').get_data(as_text=True) assert ('mf_newspaces' in data and 'num_forms' in data - and 'mf_subspaces' in data and 'sub_mult' in data - and 'mf_newspace_portraits' in data and "data:image/png;base64" in data - and 'mf_hecke_newspace_traces' in data and 'trace_an' in data) + and 'mf_newspace_portraits' in data and "data:image/png;base64" in data) data = self.tc.get('/ModularForm/GL2/Q/holomorphic/data/13.2.e.a').get_data(as_text=True) assert ('mf_newforms' in data and 'field_disc_factorization' in data and diff --git a/lmfdb/classical_modular_forms/test_cmf2.py b/lmfdb/classical_modular_forms/test_cmf2.py index c8cd64e362..114cefc619 100644 --- a/lmfdb/classical_modular_forms/test_cmf2.py +++ b/lmfdb/classical_modular_forms/test_cmf2.py @@ -132,11 +132,6 @@ def test_download_search(self): for elt in ["20.5.b", "20.5.d", "20.5.f"]: assert elt in page.get_data(as_text=True) - page = self.tc.get('/ModularForm/GL2/Q/holomorphic/?Submit=sage&download=1&query=%7B%27dim%27%3A+%7B%27%24gte%27%3A+2000%7D%2C+%27num_forms%27%3A+%7B%27%24exists%27%3A+True%7D%7D&search_type=SpaceTraces', follow_redirects=True) - assert 'Error: We limit downloads of traces to' in page.get_data(as_text=True) - page = self.tc.get('/ModularForm/GL2/Q/holomorphic/?Submit=sage&download=1&query=%7B%27dim%27%3A+%7B%27%24gte%27%3A+30000%2C%27%24lte%27%3A30600%7D%2C%27num_forms%27%3A+%7B%27%24exists%27%3A+True%7D%7D&search_type=SpaceTraces', follow_redirects=True) - assert '863.2.c' in page.get_data(as_text=True) - def test_random(self): r""" Test that we don't hit any error on a random newform diff --git a/lmfdb/verify/mf/mf_hecke_newspace_traces.py b/lmfdb/verify/mf/mf_hecke_newspace_traces.py deleted file mode 100644 index 68c9f1fe86..0000000000 --- a/lmfdb/verify/mf/mf_hecke_newspace_traces.py +++ /dev/null @@ -1,8 +0,0 @@ - -from lmfdb import db -from .mf import TracesChecker - -class mf_hecke_newspace_traces(TracesChecker): - table = db.mf_hecke_newspace_traces - base_table = db.mf_newspaces - base_constraint = {'traces':{'$exists':True}} diff --git a/lmfdb/verify/mf/mf_newspaces.py b/lmfdb/verify/mf/mf_newspaces.py index db28feeafa..3b14a485dc 100644 --- a/lmfdb/verify/mf/mf_newspaces.py +++ b/lmfdb/verify/mf/mf_newspaces.py @@ -6,7 +6,7 @@ from lmfdb.lmfdb_database import db, SQL from .mf import MfChecker, check_analytic_conductor -from ..verification import overall, overall_long, fast, slow, accumulate_failures +from ..verification import overall, fast, slow, accumulate_failures @cached_function @@ -234,33 +234,6 @@ def check_hecke_orbit_dims_sorted(self): # TIME about 2s return self.check_sorted('hecke_orbit_dims') - ### mf_hecke_newspace_traces ### - @overall_long - def check_traces_count(self): - """ - there should be exactly 1000 records in mf_hecke_traces for each record in mf_newspaces with traces set - """ - # TIME about 800s - return self.check_crosstable_count('mf_hecke_newspace_traces', 1000, 'hecke_orbit_code', constraint={'traces':{'$exists':True}}) - - @overall_long - def check_traces_match(self): - """ - check that traces[n] matches trace_an in mf_hecke_newspace_traces - """ - # TIME about 1000s - return self.check_crosstable_aggregate('mf_hecke_newspace_traces', 'traces', 'hecke_orbit_code', 'trace_an', sort=['n'], truncate=1000, constraint={'traces':{'$exists':True}}) - - ### mf_subspaces ### - @overall - def check_oldspace_decomposition_totaldim(self): - """ - check that summing sub_dim * sub_mult over rows with a given label gives dim of S_k^old(N,chi) - """ - # TIME about 20s - # from mf_subspaces - return self.check_crosstable_dotprod('mf_subspaces', 'cusp_dim', 'label', ['sub_mult', 'sub_dim']) - ### mf_newspace_portraits ### @overall def check_portraits_count(self): diff --git a/lmfdb/verify/mf/mf_subspaces.py b/lmfdb/verify/mf/mf_subspaces.py deleted file mode 100644 index 92a0f7b078..0000000000 --- a/lmfdb/verify/mf/mf_subspaces.py +++ /dev/null @@ -1,41 +0,0 @@ - -from lmfdb import db -from .mf import SubspacesChecker -from ..verification import overall - -class mf_subspaces(SubspacesChecker): - table = db.mf_subspaces - label = ['level', 'weight', 'char_orbit_label'] - uniqueness_constraints = [['label', 'sub_label']] - - @overall - def check_sub_label(self): - """ - check that sub_label matches matches sub_level, weight, sub_char_orbit_index - """ - # TIME about 2s - return self.check_string_concatenation('sub_label', ['sub_level', 'weight', 'sub_char_orbit_label']) - - @overall - def check_char_orbit_label(self): - """ - check that char_orbit_label matches char_orbit_index - """ - # TIME about 20s - return self.check_letter_code('char_orbit_index', 'char_orbit_label') - - @overall - def check_sub_char_orbit_label(self): - """ - check that sub_char_orbit_label matches sub_char_orbit_index - """ - # TIME about 20s - return self.check_letter_code('sub_char_orbit_index', 'sub_char_orbit_label') - - @overall - def check_sub_dim(self): - """ - check that sub_dim = dim S_k^new(sub_level, sub_chi) - """ - # TIME about 20s - return self.check_crosstable('mf_newspaces', 'sub_dim', 'sub_label', 'dim', 'label') diff --git a/lmfdb/verify/verification.py b/lmfdb/verify/verification.py index 678c926f50..dbe83bc8c6 100644 --- a/lmfdb/verify/verification.py +++ b/lmfdb/verify/verification.py @@ -635,7 +635,6 @@ def check_crosstable_dotprod(self, other_table, col1, join1, col2, join2=None, c """ Check that col1 is the sum of the product of the values in the columns of col2 over rows of other_table with self.table.join1 = other_table.join2. - There are some peculiarities of this method, resulting from its application to mf_subspaces. col1 is allowed to be a pair, in which case the difference col1[0] - col1[1] will be compared. col2 does not take value col1 as a default, since they are playing different roles.