Code Monkey home page Code Monkey logo

morphosource-api's People

Contributors

juliewinchester avatar

Stargazers

 avatar

Watchers

 avatar  avatar

morphosource-api's Issues

Access thumbnail image from API

Is it possible to get the thumbnail image that appears in searches as a return from the API? This is helpful for sorting out CT scans from the pictures that sometimes get uploaded along with the scans.

Screenshot 2023-10-25 at 1 37 11 PM

Taxonomy in media list

@JulieWinchester we are rebuilding the MorphoSourceImport module with the new API and the python package @johnbradley put together (https://github.com/Imageomics/pyMorphoSource)

However, we need to be able to filter list of media by higher taxonomy (e.g., Primates, Mammalia etc), otherwise it is very hard to know what to search for (taxonomy at media seems limited to binomial species names only). We discussed a few solution here. I wonder if you have suggestions, or possible to implement this inthe API?

Allow searching multiple words and ignore case with Taxonomy (GBIF)

The Search Media API endpoint (/api/media) has a Taxonomy (GBIF) (f.taxonomy_gbif) query parameter.
Currently this parameter only works when a user queries with a single word and is case sensitive.
It would be helpful for this parameter to allow multiple words and be case insensitive.

Examples

The following examples use curl and jq.

If a user searches for "Pan troglodytes" no items are returned:

curl --silent --request GET \
  --header 'Accept: application/json' \
  --url 'https://www.morphosource.org/api/media?f.taxonomy_gbif=Pan+troglodytes' \
  | jq '.response .pages .total_count'
0

If a user searches for "Pan" 4484 items are returned:

curl --silent --request GET \
  --header 'Accept: application/json' \
  --url 'https://www.morphosource.org/api/media?f.taxonomy_gbif=Pan' \
  | jq '.response .pages .total_count'
4484

If a user searches for "troglodytes" 4455 items are returned:

curl --silent --request GET \
  --header 'Accept: application/json' \
  --url 'https://www.morphosource.org/api/media?f.taxonomy_gbif=troglodytes' \
  | jq '.response .pages .total_count'
4455

If a user searches for "pan" 0 items are returned:

curl --silent --request GET \
  --header 'Accept: application/json' \
  --url 'https://www.morphosource.org/api/media?f.taxonomy_gbif=pan' \
  | jq '.response .pages .total_count'
0

Access File Object Details

Is it possible to return the "File Object Details" with the API? In particular, file size is very important prior to download.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.