Skip to content
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

Create previously non-existent folios during mei indexing #892

Merged
merged 3 commits into from
Aug 15, 2024

Conversation

dchiller
Copy link
Collaborator

@dchiller dchiller commented Aug 6, 2024

Closes #889.

When chants end on a folio where no other chants begin, the folio does not exist in CantusDB but does have an MEI file. Folio A14r in Salzinnes is a good example of this:

image

There is only one line of music on this folio -- the ending of a chant that begins on the previous folio. Thus, we have no chant in CantusDB that has folio "A14r", but we do have a MEI file for folio "A14r" from the OMR process.

This PR modifies the index_manuscript_mei command to create a folio in such cases (we check that it's a "real" folio by making sure the mei file follows a naming convention and then create the folio if it doesn't exist). The user is alerted to this, and then must manually add the image_uri to the folio (either through the admin panel or the map folios process) and then reindex the mei. This process if further detailed in issue #891.

This is convoluted, but a more comprehensive solution (for example, by adjusting the map folios process) seems ill-advised at the moment given upcoming changes to the Cantus Ultimus data import and indexing process to more closely couple it to CantusDB. We'll want to come up with a better solution for these cases (hence, #891) after those changes. Note that this is also relevant to longstanding #628, which we should also come back to at that time.

… mei

When chants end on a folio where no other chants begin, the folio
does not exist in CantusDB but does have an MEI file. For example, see
folio A14r in Salzinnes. Here, we modify the index_manuscript_mei
command to create a folio in such cases (we check that it's a "real"
folio by making sure the mei file follows a naming convention and then
create the folio if it doesn't exist). The user is alerted to this, and
they must manually add the image_uri to the folio (either through the admin
panel or the map folios process) and then reindex the mei. This is detailed
in issue DDMAL#891. This is convoluted, but given that we're going to change the
structure of the CU database soon so that it is more closely coupled with
CantusDB, we'll figure out a more permanent solution then -- solving DDMAL#891).
@dchiller
Copy link
Collaborator Author

@lucasmarchd01 Could you take a look at this?

@lucasmarchd01
Copy link
Contributor

Oops sorry I missed this, yes!

Specifically silences the `import-untyped` error on the import
of `SolrConnection` from `solr.core`
@dchiller dchiller merged commit 949b013 into DDMAL:main Aug 15, 2024
2 checks passed
@dchiller dchiller deleted the i889-mei-index-no-folio branch August 15, 2024 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OMR indexing fails when we have MEI for a folio that does not exist in DB
2 participants