Opened 7 years ago

Last modified 7 years ago

#16408 new enhancement

Map database

Reported by: vdelecroix Owned by:
Priority: major Milestone: sage-6.4
Component: combinatorics Keywords:
Cc: pdehaye, ​stumpc5, VivianePons, mantepse Merged in:
Authors: Reviewers:
Report Upstream: N/A Work issues:
Branch: u/vdelecroix/experimental-combinatorial_map_database (Commits, GitHub, GitLab) Commit: 26142c40aec12804c9d744b5807057a9e57b780d
Dependencies: #16410 Stopgaps:

Status badges

Description (last modified by vdelecroix)

The current implementation of combinatorial_map modifies some methods of objects in order to tag them as being a "combinatorial map" (it might be not the case anymore with #16410). In this ticket we propose an implementation of a database (sage.databases.map_database) and a decorator (@register_method_as_map) which register the methods but do not modify them. Contrarily to the previous implementation, the version proposed here is centralized. Which is actually consistent with the fact that we want to do some queries.

Problems:

  • the database is built in two times. At startup, (more precisely when the code is executed) the decorator fills a list of constructions. Then, at the first call of MapDatabase() the corresponding maps are actually built.
  • some objects have no general enough parents: AlternatingSignMatrix, Core, OrderedSetPartition and the more delicate Poset, Graph (Vincent: I think that we might fix the three first in some tickets and use a hack for the two last with Set_PythonType).

Further development:

  • add more information into morphisms (especially injectivity/surjectivity, order for endomorphism, ...)

Change History (4)

comment:1 Changed 7 years ago by pdehaye

This looks great! Thanks Vincent for doing this.

comment:2 Changed 7 years ago by vdelecroix

  • Branch set to u/vdelecroix/experimental-combinatorial_map_database
  • Commit set to 26142c40aec12804c9d744b5807057a9e57b780d
  • Dependencies set to #16410
  • Description modified (diff)
  • Summary changed from Combinatorial map database to Map database

I will not work on this anymore before having some constructive comments. Or even better, somebody else contribution. If you apply my branch the file sage/combinat/combinatorial_map.py becomes almost empty and I might fix it later on.

Vincent


New commits:

e710102experimental redesign of combinatorial maps
d1fac91Move the database to databases.map_database
00aa803forgot the file map_database.py
26142c4much simpler implementation

comment:3 Changed 7 years ago by mantepse

  • Cc mantepse added

comment:4 Changed 7 years ago by vbraun_spam

  • Milestone changed from sage-6.3 to sage-6.4
Note: See TracTickets for help on using tickets.