PNG  IHDR;IDATxܻn0K )(pA 7LeG{ §㻢|ذaÆ 6lذaÆ 6lذaÆ 6lom$^yذag5bÆ 6lذaÆ 6lذa{ 6lذaÆ `}HFkm,mӪôô! x|'ܢ˟;E:9&ᶒ}{v]n&6 h_tڠ͵-ҫZ;Z$.Pkž)!o>}leQfJTu іچ\X=8Rن4`Vwl>nG^is"ms$ui?wbs[m6K4O.4%/bC%t Mז -lG6mrz2s%9s@-k9=)kB5\+͂Zsٲ Rn~GRC wIcIn7jJhۛNCS|j08yiHKֶۛkɈ+;SzL/F*\Ԕ#"5m2[S=gnaPeғL lذaÆ 6l^ḵaÆ 6lذaÆ 6lذa; _ذaÆ 6lذaÆ 6lذaÆ RIENDB`  [/\c@@sddlmZddlmZddlmZddlmZidd6dd6d d 6d d 6Zd ZdefdYZ dS(i(tabsolute_import(tprint_function(tunicode_literals(treduceiunameiusummaryiu descriptioniuurlcC@s+t|}dg||t|}|S(u, Ordered sset with empty strings prepended. u(tlentsorted(tssettlengthtcurrenttl((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyt_canonize_string_set"s t MatchCountercB@seZdZedZedZdZdZdZdZ dZ dZ d Z e d d Zd ZRS( uMap packages to which of their attributes matched in a search against what values. The mapping is: ``package -> [(key, needle), ... ]``. c@s"fd}tt||S(Nc@sG|d}|d}t|}||kr5dnd}|t|S(Niii(tgetattrtWEIGHTS(tmatchtkeytneedlethaystacktcoef(tpkg(s5/usr/lib/python2.7/site-packages/dnf/match_counter.pytweight4s   (tsumtmap(RtmatchesR((Rs5/usr/lib/python2.7/site-packages/dnf/match_counter.pyt _eval_weights1scC@sJd}x=|D]5\}}t||}|t|t|7}q W|S(Ni(R R(RRtdistRRR((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyt_eval_distance=s c@s"jfd}|S(uGet the key function used for sorting matches. It is not enough to only look at the matches and order them by the sum of their weighted hits. In case this number is the same we have to ensure that the same matched needles are next to each other in the result. Returned function is: pkg -> (weights_sum, canonized_needles_set, -distance) c@s@j||tj|j|| fS(N(RR tmatched_needlesR(R(t max_lengthtself(s5/usr/lib/python2.7/site-packages/dnf/match_counter.pytget_keyRs(t _max_needles(RR((RRs5/usr/lib/python2.7/site-packages/dnf/match_counter.pyt _key_funcEs c@s$r tfdDSdS(u0Return the max count of needles of all packages.c3@s$|]}tj|VqdS(N(RR(t.0R(R(s5/usr/lib/python2.7/site-packages/dnf/match_counter.pys [si(tmax(R((Rs5/usr/lib/python2.7/site-packages/dnf/match_counter.pyRXscC@s#|j|gj||fdS(N(t setdefaulttappend(RRRR((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pytadd^scC@s-x&|D]}td|||fqWdS(Nu%s %s(tprint(RR((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pytdumpas c@stfd|DS(Nc3@s"|]}t|dVqdS(iN(R (R!tm(R(s5/usr/lib/python2.7/site-packages/dnf/match_counter.pys fs(tset(RR((Rs5/usr/lib/python2.7/site-packages/dnf/match_counter.pytmatched_haystacksescC@std||DS(Ncs@s|]}|dVqdS(iN((R!R(((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pys is(R)(RR((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyt matched_keyshscC@std||DS(Ncs@s|]}|dVqdS(iN((R!R(((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pys ls(R)(RR((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyRkscC@s4|r |n |j}t|d|jd|S(NRtreverse(tkeysRR (RR,tlimit_toR-((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyRnsc@stfddS(Nc@s|t|S(N(R(ttotalR(R(s5/usr/lib/python2.7/site-packages/dnf/match_counter.pytssi(R(R((Rs5/usr/lib/python2.7/site-packages/dnf/match_counter.pyR/rsN(t__name__t __module__t__doc__t staticmethodRRR RR%R'R*R+RtFalsetNoneRR/(((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyR )s        N( t __future__RRRt functoolsRR R tdictR (((s5/usr/lib/python2.7/site-packages/dnf/match_counter.pyts