monarch-initiative / owlsim-v3

Ontology Based Profile Matching
16 stars 5 forks source link

WIP: first pass at frequency-awareness #60

Closed cmungall closed 7 years ago

cmungall commented 7 years ago

issue #56

cmungall commented 7 years ago

@jnguyenx do you know why travis is complaining? UPDATE ah I just needed to reload my tab, it succeeds now I have reduced logging. As you were!

jnguyenx commented 7 years ago

That's my magic karma. Just tag me and it'll resolve the issue.

julesjacobsen commented 7 years ago

I'm working on integrating owlsim3 into Exomiser at the moment - see #62 and #57 for related issues. Jeremy has moved the Guice dependencies into the server code but we still need to make a clearer mechanism for providing the source data to the application on startup.

drseb commented 7 years ago

Do you think it will be possible to use it without Guice, without Spring, and not as a server?

julesjacobsen commented 7 years ago

Absolutely - I don't think there is any real requirement for any DI framework. Unless I've missed something important, the 'tricky' part is getting the right data sorted and loading this into a BMKnowledgeBase. This is the sort of thing you would want to do in the DI managed application, but it shouldn't be reliant on it.

For example:

public MatchSet matchPhenodigm(Set<String> ids, BMKnowledgeBase bmKnowledgeBase) throws IncoherentStateException {
    ProfileMatcher phenodigmProfileMatcher = PhenodigmICProfileMatcher.create(bmKnowledgeBase);
    ProfileQuery query = ProfileQueryFactory.createQuery(ids);
    logger.info("Querying with Class ids: {}", query.getQueryClassIds());
    return phenodigmProfileMatcher.findMatchProfile(query);
}

You provide the BMKnowledgeBase to the ProfileMatcher as it can take a long time to load all the data. Hence Dependency Injection.

cmungall commented 7 years ago

See #65 for making it easier to use as a java lib