NOAA-ORR-ERD / OilLibrary

The NOAA library of oils and their properties.
Other
11 stars 17 forks source link

Oil types rejected due to heavy SA components #1

Closed knutfrode closed 7 years ago

knutfrode commented 7 years ago

Hi, When installing, several of the oils in the OilLib file are not inserted into the database, but rejected with the reason 'Oil has heavy SA components' Is there any workaround to be able to use these oils as well?

ChrisBarker-NOAA commented 7 years ago

We have just refactored the component estimation code, so I think this may no longer be an issue.

@JamesMakela: If the code's ready, could you push a new version to gitHub, and see if that addresses this issue?

-CHB

JamesMakela-NOAA commented 7 years ago

Ok guys, I have pushed a new tagged release (v0.0.8). In my testing, I found this to have resolved the issue with all existing oils that were previously failing due to heavy volatile components.

@knutfrode: Try it out and let us know how it goes.

knutfrode commented 7 years ago

This works fine. I have installed and tested v0.0.8, and no oils are now rejected due to heavy volatile components. Some oils are still rejected due to mismatch between API and density, but these are much fewer (~20?)

INFO:oil_library.init_oil:(oil.api, api_from_density) = (52.0, 50.8453608247)
WARNING:oil_library.init_oil:OilRejected(oil=AD02538,
                                         errors=['Oil API does not match its density'])
ChrisBarker-NOAA commented 7 years ago

yes -- API and density are the same thing, of course.

In the input data, the API is specified directly and records can also have measured density at various temperatures. The API should be the density at 15C -- but if there is a mis-match there is an error in the record somewhere, so we dont want to include it in the working version.

We really need to go in by hand to each of these records and see what the problem is.

-CHB

knutfrode commented 7 years ago

In the newest version (0.0.10) quite a few oils are rejected at installation time for two different reasons:

WARNING:oil_library.init_oil:OilRejected(oil=AD03077, errors=['Oil has heavy SA components'])
WARNING:oil_library.init_oil:OilRejected(oil=AD03078, errors=['Imported Record has insufficient cut data'])