Open chenejac opened 4 years ago
Andrew Woods said:
What would you considered "fixed"? ..that the image uploader searches beyond the kb2 graph?
Don Elsborg said:
correct. It should find the individual in any graph. I'm trying some debugging now and sparql queries that come up show it's search kb2 and the inference graph to see if the person is a foaf:person. We explicitly state this in our own named graph.
I'm still not sure exactly where and how these queries get called. Perhaps [~accountid:557058:3f53c733-6ac2-4e92-9f12-e34e297283a3] or [~accountid:557058:a0d46356-8afd-4951-bfbb-1b29b1a511b5] might know.
Benjamin Gross said:
[~accountid:5e347720a834270cb0997fb6] I haven't been able to replicate this problem. Can you give some more details on what happens? It only happens sometimes?
Edit- Hmm, do you have inferencing turned off? I loaded the person triples to a separate graph but maybe it's working due to the triples added to the kb-inf graph.
Don Elsborg said:
Hi Benjamin,
Issue is that someone uploads or even replaces an image, Then the image doesn't appear. The triples are created with the exception of the mainImage triple. The files are also on the disk. I don't have inferencing on. I do create triples manually, like person a foaf:Agent I can try an experiment with inferencing though.
Benjamin Gross said:
Can you post an example triple set (for a person) where the image upload fails? I would like to turn inferencing off and try it on my end to reproduce the problem.
Don Elsborg said:
There aren't triples associated with the person for a failure. But I use this code to identify the "orphans"
// code placeholder
SELECT ?mainImage ?mainDownloadLocation ?mainDownloadUrl ?mainFilename ?thumbDownloadLocation#?thumbDownloadUrl ?thumbFilenameWHERE{ ?mainImage vitro:downloadLocation ?mainDownloadLocation . optional { ?mainDownloadLocation vitro:directDownloadUrl ?mainDownloadUrl } optional { ?mainImage vitro:filename ?mainFilename } ?mainImage vitro:thumbnailImage ?thumbNail . ?thumbNail vitro:downloadLocation ?thumbDownloadLocation * optional { ?thumbDownloadLocation vitro:directDownloadUrl ?thumbDownloadUrl }* optional { ?thumbNail vitro:filename ?thumbFilename } FILTER NOT EXISTS { ?person vitro:mainImage ?mainImage } }
Benjamin Gross said:
I just mean, which triples are present for a person in your system? I'm wondering which triple being added by inferencing makes it always work for me.
Don Elsborg (Migrated from VIVO-1738) said:
CU Boulder's VIVO has people and data that aren't in the main kb2 graph.
For CU, there are frequent occasions where the uploads of an image do not complete.
Most triples are created but a missing link triple isn't. This triple takes the form of: https://experts.colorado.edu/individual/fisid_165827> http://vitro.mannlib.cornell.edu/ns/vitro/public#mainImage https://experts.colorado.edu/individual/n6515 so ?personIndividual #mainImage ?fileLocation
Several years ago I believe Brian Lowe mentioned that this is happening because we don't store our people in the main kb2 graph and that the image uploader specifically searches the kb2 graph for people. Would like to get this fixed and understand where the image uploader code block is.
Not sure, but starting to look in this area for a fix: [https://github.com/vivo-project/Vitro/blob/develop/api/src/main/java/edu/cornell/mannlib/vitro/webapp/dao/jena/IndividualJena.java#L197]