{% load sorl_thumbnail ocyan_thumbnail %}
{% retina thumb 0.5 options=options as small %}

{% if mobile %}{# if a mobile rendition was explicitly passed to the templatetag, use that one #}
<data-src {% if type %}type="{{ type }}"{% endif %} srcset="{{ thumb.url }} {{ thumb.width }}w, {{ small.url }} {{ small.width }}w, {{ mobile.url }} {{ mobile.width }}w"></data-src>
{% else %}
{% retina thumb 0.3 options=options as smallest %}
<data-src {% if type %}type="{{ type }}"{% endif %} srcset="{{ thumb.url }} {{ thumb.width }}w, {{ small.url }} {{ small.width }}w, {{ smallest.url }} {{ smallest.width }}w"></data-src>
{% endif %}