AtlasOfLivingAustralia / biocache-service

Occurrence & mapping webservices
https://biocache-ws.ala.org.au/ws/
Other
9 stars 26 forks source link

Organism quantity integer is changed to float in record view (biocache) #816

Open sat01a opened 1 year ago

sat01a commented 1 year ago

eg https://biocache-test.ala.org.au/occurrences/4c433838-cace-4ab3-bb01-143d44a9f2af

adam-collins commented 1 year ago

Clarification required. There are occurrences without whole number quantities, e.g. https://biocache.ala.org.au/occurrences/search?q=organismQuantity:0.6667

adam-collins commented 1 year ago

@peggynewman what are your thoughts?

peggynewman commented 1 year ago
image

My thoughts are that it should probably just be displayed as provided, otherwise we are insinuating meaning ourselves.

adam-collins commented 1 year ago

The suggestion is to remove the processed organismQuantity value. This is a Double value stored as a String in SOLR. There is no associated quality assertion when a non-parsable Double value is supplied.

Some options that I think are in line with this request:

Of interest may be the unprocessed raw_organismQuantity values https://biocache.ala.org.au/ws/occurrences/search?q=raw_organismQuantity:*&fq=-organismQuantity:*&facet=true&facets=raw_organismQuantity&pageSize=0&flimit=-1

peggynewman commented 1 year ago

The above was from the sampling-event docs for the IPT. This is the DwC definition:

image

The values that didn't process are a lot of ranges, and those that did are either integers or floats, with quite a few integers being estimates (eg "25000") so to add the precision of a .0 isn't helpful I don't think.

My take is to follow the standard as closely as we can, so option #2 looks best for me. If the GBIF pipeline needs changing then we can do that. What do you think?

adam-collins commented 1 year ago

Moving the issue to https://github.com/gbif/pipelines/issues/922

adam-collins commented 7 months ago

pull request https://github.com/gbif/pipelines/pull/1002

peggynewman commented 5 months ago

1 is no longer 1.0 https://biocache-test.ala.org.au/occurrences/4c433838-cace-4ab3-bb01-143d44a9f2af 0.667 still works https://biocache-test.ala.org.au/occurrences/search?q=organismQuantity:0.6667#tab_recordsView raw_organismQuantity is gone LGTM, tick