materialsproject / emmet

Be a master builder of databases of material properties. Avoid the Kragle.
https://materialsproject.github.io/emmet/
Other
55 stars 68 forks source link

missing task_type field for non-GGA calculations #258

Open rkingsbury opened 3 years ago

rkingsbury commented 3 years ago

It appears that the task_type field is blank or null for all non-GGA tasks in Knowhere/tasks. I discovered this when testing the API tasks endpoint on r2SCAN, SCAN, and PBEsol tasks. Checking the database collection gives

image

For example, try task_ids

For all of these, the task_type field is actually missing from the document.

shyamd commented 3 years ago

Is it possible the task_type functionality isn't working for these calcs or is just in the materials docs where this is going awry?

rkingsbury commented 3 years ago

This is actually in the task docs (or whatever it is that the Tasks endpoint serves from) not the materials docs . Could this be a simple question of when the tasks were ingested? In my personal tasks collection, none of my tasks has a task_type field.

The validation and materials collections associated with my PR #536 (building with the new build system) on Knowhere / mp_core_build appear to have correctly-populated calc_type and calc_types fields, respectively.

shyamd commented 3 years ago

The task docs won't have a valid task_type since I think that was hot-patched for a short while until I realized that even pymatgen was buggy and decided that it should be in the Materials Doc.

mkhorton commented 3 years ago

In that case, we should probably remove task_type from the API doc?

I see the value in having it from the tasks endpoint directly, but since it needs to be built separately, one option would be to offer a /tasks/task_types route. Another option would be an on-the-fly aggregation, so that the returned task doc has the built task type, but that would probably mean we couldn't search on it.