+
    ¥Âk!  ã                   ó  € R t ^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RIt^ RI	H
t
Ht ^ RIHt ^ RIHt ^ RIt^ RIt]! ]4      P+                  4       P,                  ^,          t]R,          tR tR tR	 t]R
8X  d
   ]! 4        R# R# )zICompare frozen, image-only alternative ordering on saved toy-focus masks.N)ÚPath)ÚImageÚ	ImageDraw)Útranslation_hypotheses)Úbuild_variantszresults/r60c                 óx   € \         P                  ! \        V 4      P                  4       4      P	                  4       # )N)ÚhashlibÚsha256r   Ú
read_bytesÚ	hexdigest)Úps   &Ú%research/r60_multiplane_hypotheses.pyÚshar      s&   € ”'—.’.¤ a£×!3Ñ!3Ó!5Ó6×@Ñ@ÓBÐBó    c           	      óZ  € \         P                  ! R R	R4      p\        P                  ! V4      p\	        V4       EFY  w  pw  rg\         P
                  ! V 4      P                  R4      p\         P                  ! RVP                  R
4      p	\	        V4       F‰  w  r«. ROV
^,          ,          p\         P                  ! RVP                  V4      qÝP                  \         P
                  ! VP                  R4      ^d,          4      4       \         P                  ! W�4      p	K‹  	  VP                  \         P                  ! W‰4      P                  R 4      P                  R4      VR,          ^34       VP                  VR,          ^,           ^3VRR7       EK\  	  VP                  V^UR7       R# )ÚRGBi@  ÚwhiteÚRGBAÚuint8z#202a28)Úfill)ÚqualityN)i   i^  )é    r   r   r   )z#00b886z#e85956z#9670dfz#e7ba16)é6  r   )r   Únewr   ÚDrawÚ	enumerateÚ	fromarrayÚconvertÚsizeÚputalphaÚastypeÚalpha_compositeÚpasteÚresizeÚtextÚsave)ÚimageÚgroupsÚpathÚcanvasÚdÚiÚnameÚmasksÚimÚlayerÚjÚmÚcolorÚcs   &&&           r   Úpanelr4      s…  € Ü�	Š	�%˜ GÓ,€¬y¯~ª~¸fÓ/E¨QÜ  ×(�^€Q�|ˆÜ
‡_‚_�UÓ×#Ñ# FÓ+€"´%·)²)¸FÀ2Ç7Á7È9Ó2U¨EÜ�uÖ�c€aÚ	2°1°Qµ3Õ	7€5¼%¿)º)ÀFÈ2Ï7É7ÐSXÓ:Y¸×ZdÑZdÔej×etÒetÐuv×u}Ñu}ð  Fó  vGð  HKõ  vKó  fLô  [Mô  TY÷  Tiò  Tið  joó  Trò  NSñ à‡,�,Œu×$Ò$ RÓ.×6Ñ6°uÓ=×DÑDÀYÓOÐQRÐSVÕQVÐWYÐPZÔ[Ð\]×\bÑ\bÐdeÐfiÕdiÐjkÕdkÐlmÐcnÐosð  zCÐ\b÷  ]Dñ	 )ð
 ‡�ˆT˜"€Ör   c                  ó€  aa*€ \         P                  ! \        R ,          P                  4       4      p V R,           FE  p\	        \
        VR,          ,          4      VR,          8w  g   K.  \        RVR,          ,           4      h	  \        R,          P                  4       '       d   \        R4      h. p\        V R,          ^4       EFn  w  r4\        P                  ! 4       p\
        VR,          ,          p\        P                  ! VR	R
7      p\        VR,          4      p\        P                  ! VR,          4      R\        P                   ! V4       P#                  V4      P%                  \&        4      p	\)        VR,          VR,          V	4       U
UUu. uF   w  r«pR\+        V
4      R\-        V4      RV/NK"  	  ppp
p\/        V Uu0 uF  qîR,          kK  	  up4      \/        V4      8w  d   \        R4      hVR,          p\1        VR,          P%                  \&        4      4      p/ p/ p\3        ^4       Fn  pV^8X  d   K  \5        V^,          Wû,          RR7      pVP7                  4        UUu/ uF  w  ppVR8w  g   K  VVbK  	  uppV\+        V4      &   VR,          VV&   Kp  	  \9        VV4      pVR,          p\        P:                  ! \        RVR R2,          V'       dO   \        P<                  ! \        P>                  ! V Uu. uF  qîR,          NK  	  up4      PA                  4       4      M\        PB                  ! . RR7      \        PB                  ! \/        V4      .VPD                  R ,          O4      \        PB                  ! V Uu. uF  qîR,          NK  	  up4      \        PB                  ! V Uu. uF  qîR!,          NK  	  up4      \        PB                  ! V Uu. uF  qîR,          NK  	  up4      \        PB                  ! V Uu. uF  qîR",          NK  	  up4      \        PB                  ! V Uu. uF  qîR#,          NK  	  up4      \        PB                  ! V Uu. uF  qîR$,          NK  	  up4      R%7	       / p/ pVP7                  4        Fñ  w  o*pV Uu. uF#  qîR,          PG                  4       '       g   K!  VNK%  	  pp\H        PJ                  ! VR&4      w  ppVVS*&   R'\/        V4      R(\/        V4      \/        V4      ,
          R)\/        V4      R*TR+V Uu. uF  qîR,          NK  	  upR,Rk Uu/ uF(  p\+        V4      \L        PN                  ! VVRV R-4      bK*  	  upR.\L        PN                  ! VVR-4      /VS*&   Kó  	  VR/,          R08X  d8   VR1,          pVR2,          R,,          R3,          R4,          V8w  d   \        R54      h\Q        V^,          R6V3R7VR2,          R8,           Uu. uF  qîR,          NK  	  up3R9VR:,          R8,           Uu. uF  qîR,          NK  	  up3R;VR,          R8,           Uu. uF  qîR,          NK  	  up3.\        R<VR R=2,          4       / VCR>\/        V4      R?VR@VRA\S        \        P                  ! 4       V,
          ^4      RBRVR R2RCR<VR R=2/Cp VPU                  V 4       \W        V RD\/        V R,          4       REVR/,           RFVRG,           RHVRI,           RF2
RFPY                  RJ VP7                  4        4       4      ,           RKRL7       EKq  	  RMRNRO\	        \        R ,          4      RPVRQRR/p!\        R,          P[                  \         P\                  ! V!^RS7      RT,           4       . p"V EF]  p#V#R@,          p$V"PU                  RU\^        P`                  ! V#RG,          4      ,           RV,           \+        V#RI,          4      ,           RW,           V#RC,          ,           RX,           \+        V$R2,          R,,          R3,          R4,          4      ,           RY,           \+        V$R:,          R,,          R3,          R4,          4      ,           RZ,           \+        V$R,          R,,          R3,          R4,          4      ,           R[,           \+        V$R,          R',          4      ,           R\,           \+        V$R,          R),          4      ,           R],           4       EK`  	  R^p%Rl Fœ  o*Rk Uau. uF  o\c        V*V3R_ lV 4       4      NK  	  p&p\c        V*3R` lV 4       4      p'\c        V*3Ra lV 4       4      p(\c        V*3Rb lV 4       4      pV%RcS* RdV&^ ,           RdV&^,           RdV&^,           RdV' RdV( ReV Rf2,          p%Kž  	  RgPe                  RhV%4      Pe                  RiR^PY                  V"4      4      p)\        Rj,          P[                  V)4       R# u uppp
i u upi u uppi u upi u upi u upi u upi u upi u upi u upi u upi u upi u upi u upi u upi u upi u upi )mzprotocol.jsonÚinputsr(   r	   zFrozen input changed: zresults.jsonzPreserve previous resultÚ	selectionÚarchiveF)Úallow_pickleÚcandidate_shapeÚcandidate_bitsNÚcandidate_idsÚcandidate_zÚidÚzÚmaskzNonunique candidate IDsÚplanesÚ
full_masksÚhann)ÚwindowÚsurfaceÚpeaksÚmulti_interleavedzalternatives-Ú02dz.npzr   )Údtype:é   NNÚ	source_idÚdxÚdyÚbranch)r;   r:   r<   Ú
source_idsr?   rL   rM   rN   gš™™™™™é?ÚexpandedÚempty_after_shiftÚretainedÚaliasesÚrankingÚbudgetsg      à?ÚallÚdatasetÚr58Úprevious_top20ÚunregisteredÚ20Úmatchedz)Raw score does not reproduce prior resultzSynthetic full maskszUnregistered top 20:Né   NzOne shift top 20Úphase_singlezAlternatives top 20zscene-z.jpgÚraw_candidatesÚalignment_peaksÚscoresÚelapsed_secondsÚalternatives_archiver&   Ú/z: Ú Ú	conditionz pair Úpairc              3   ó`   "  € T F$  w  rV R VR,          R,          R,           R2x € K&  	  R# 5i)Ú:rU   r[   r\   z/2N© )Ú.0ÚkÚvs   &  r   Ú	<genexpr>Úmain.<locals>.<genexpr>.   sk   é € ð  koñ  `nñ  Y\ð  YZÐnoÐmpÐpqÐrsÐt}Õr~ð  @Dõ  sEð  FOõ  sPð  rQð  QSõ  lTó  `nùs   ‚,.T)ÚflushÚformatzr60-alignment-hypotheses-v1Úprotocol_sha256ÚrecordsÚwarningzÙSynthetic amodal masks and previously inspected sources; no expert labels, no real optical validation or real false-positive estimates. Only alignment and postprocessing timed; precomputed model inference is excluded.)ÚindentÚ
z<article><h2>u	    Â· pair z</h2><img src="zS" alt="Synthetic masks and three segmentation alternatives"><p>Top 20 matched: raw z/2; single shift z/2; alternatives z/2. Expanded alternatives z, retained after suppression z.</p></article>Ú c              3   ó~   <"  € T F2  qR ,          S,          R,          \        S4      ,          R,          x € K4  	  R# 5i)ra   rU   r\   N)Ústr)rk   ÚrÚmodeÚns   & €€r   rn   ro   5   s.   øé € ÐMÁWÀˆh�K˜Õ˜iÕ(¬¨Q«Õ0°×;Ò;ÃWùs   ƒ:=c              3   ó^   <"  € T F"  qR ,          S,          R,          R,          x € K$  	  R# 5i)ra   rV   r\   Nrj   ©rk   rz   r{   s   & €r   rn   ro   5   sQ   øé € ð  kañ  Y`ð  TUÐmuÕkvÐw{Õk|ð  ~Cõ  lDð  EN÷  lOò  lOó  Y`ùs   ƒ*-c              3   óP   <"  € T F  qR ,          S,          R,          x € K  	  R# 5i)ra   rP   Nrj   r~   s   & €r   rn   ro   5   sS   øé € ð  n^ñ  V]ð  QRð  qyõ  ozð  {õ  o@ð  AK÷  oLò  oLó  V]ùó   ƒ#&c              3   óP   <"  € T F  qR ,          S,          R,          x € K  	  R# 5i)ra   rR   Nrj   r~   s   & €r   rn   ro   5   sS   øé € ð  gWñ  OVð  JKð  jrõ  hsð  txõ  hyð  zD÷  hEò  hEó  OVùr€   z<tr><td>z	</td><td>u    â†’ z
</td></tr>uS  <!doctype html><html lang="en"><meta charset="utf-8"><meta name="viewport" content="width=device-width"><title>Alignment alternatives and segmentation</title><style>body{font:16px/1.5 system-ui;background:#f3f6ef;color:#203a38}main{max-width:1320px;margin:auto;padding:24px}.notice{background:#fff2d6;padding:16px}article{background:white;padding:14px;margin:16px 0}img{width:100%}table{border-collapse:collapse}th,td{padding:8px;border:1px solid #aaa;text-align:left}</style><main><nav><a href="/results/performance/">Performance monitor</a> Â· <a href="/research/R60.md">Research notes</a></nav><h1>Do alternative alignments recover overlapping diatoms?</h1><p class="notice">These are synthetic crossings made from public diatom images and local backgrounds. Full masks are synthetic targets, not scientist annotations. The same three source pairs recur across conditions. Real overlap accuracy, false positives and human-level performance remain unknown.</p><p>Each source candidate is aligned using either no shift, the strongest image-only phase peak, or up to three image-only peaks plus no shift. We test two candidate orderings. Candidates are suppressed at mask IoU 0.8 and matched one-to-one to synthetic targets at IoU â‰¥0.5. Full-score matching has no review-budget limit. Raw predictions and all pre-suppression alternatives remain available. Phase peaks are not calibrated confidence.</p><table><tr><th>Ordering</th><th>Top 5 / 30</th><th>Top 10 / 30</th><th>Top 20 / 30</th><th>All / 30</th><th>Expanded â†’ retained</th></tr>TABLE</table><p>Model predictions were precomputed; timings exclude model inference. The image columns show synthetic target masks, raw top 20, single-shift top 20 and interleaved alternatives top 20. Colors distinguish overlays and do not identify individual diatoms. Foreground source: GÃ¼ndÃ¼z et al., <a href="https://creativecommons.org/licenses/by-nc-sa/4.0/">CC BY-NC-SA 4.0</a>; details in <a href="/results/r58/">R58</a>.</p><p><a href="protocol.json">Frozen protocol and source hashes</a> Â· <a href="results.json">Full results and candidate orderings</a></p>CARDS</main></html>ÚTABLEÚCARDSz
index.html)é   é
   r]   )rZ   r^   Úmulti_primaryrG   )3ÚjsonÚloadsÚOUTÚ	read_textr   ÚROOTÚ
ValueErrorÚexistsÚFileExistsErrorr   ÚtimeÚ	monotonicÚnpÚloadÚtupleÚ
unpackbitsÚprodÚreshaper    ÚboolÚzipry   ÚintÚlenÚlistÚranger   Úitemsr   Úsavez_compressedÚpackbitsÚstackÚravelÚarrayÚshapeÚanyÚcontrolsÚnmsÚscoringÚmatchr4   ÚroundÚappendÚprintÚjoinÚ
write_textÚdumpsÚhtmlÚescapeÚsumÚreplace)+r   Úitemrs   ÚindexÚsrcÚstartedr(   Úar£   r-   r+   r?   r1   ÚrawÚxrA   ÚrefsrF   ÚmetadataÚinforl   rm   ÚvariantsÚall_variantsra   Ú
kept_modesr�   ÚnonemptyÚkeptrS   r|   ÚpreviousÚrecÚoutÚcardsrz   ÚsÚtableÚsumsÚfullrP   Úpager{   s+                                 `           @r   ÚmainrË      sQ  ù€ Ü‡:‚:Œs�?Õ"×-Ñ-Ó/Ó0€Øˆx�[ˆ[€TÜŒˆd�6�lÕ	Ó˜T (�^Ö+´*Ð=UÐVZÐ[aÕVbÕ=bÓ2cÐ,cñ äˆÕ×Ñ×!Ò!¬Ð8RÓ(SÐ"SØ	€Ü˜A˜k�N¨1×-�Y€UÜ
�.Š.Ó
€'¤ S¨¥^Õ 3˜4´b·g²g¸dÐPUÔ6V°AÔ]bÐcdÐevÕcwÓ]xÐW\ô  @B÷  @Mò  @Mð  NOð  P`õ  Naó  @bð  crô  df÷  dkò  dkð  lqó  drð  @s÷  @{ñ  @{ð  |Aó  @B÷  @Iñ  @Iô  JNó  @OÐy~Ü69¸!¸OÕ:LÈQÈ}ÕM]Ð^cÔ6dÕeÑ6d©U¨Q°ˆŒS�‹V�Cœ˜A›˜v aÓ(Ñ6d€#ÒeÜ™3Ó	™3�aˆD�'ˆ'™3Ñ	Ó ¤# c£(Ô*´Ð<UÓ1VÐ+VØ	
ˆ8�€&œ$˜q �×5Ñ5´dÓ;Ó<�TÀ2¸UÈrÀhÜ�Ž8€aØˆ„d‰8Ü˜v a�y¨­¸&ÔA€4Ðcg×cmÑcmÔcoô  TAÑcoÑ\_Ð\]Ð^_ÐstÐvÑsÔTWÐTUÐVWÒTWÑcoò  TAÀ(Ì3ÈqË6ÑBRð  KOð  PWõ  KXð  BGð  HIó  BJñ ô ˜#˜eÓ$€(°(Ð;NÕ2O \Ü×Ò”c˜M¨%°¨°DÐ9Õ9÷  NZÌÏÊÔUW×U]ÒU]Ñr~Ó^Ñr~ÐmnÐag×_hÐ_hÑr~Ñ^ó  VA÷  VGñ  VGó  VIô  JJô  `b÷  `hò  `hð  ikð  ryô  `zô  KM÷  KSò  KSô  UXð  Yeó  Ufð  Tyð  hn÷  htñ  htð  uwõ  hxð  Tyó  Kzô  IK÷  IQò  IQñ  dpó  Rqñ  dpð  _`ð  UY÷  SZð  SZñ  dpñ  Rqó  Irô  ~@÷  ~Fò  ~Fñ  `ló  Gmñ  `lð  [\ð  JU÷  HVð  HVñ  `lñ  Gmó  ~nô  qs÷  qyò  qyñ  KWó  zXñ  KWð  FGð  }@÷  {Að  {Añ  KWñ  zXó  qYô  ]_÷  ]eò  ]eñ  xDó  fEñ  xDð  stð  im÷  gnð  gnñ  xDñ  fEó  ]Fô  JL÷  JRò  JRñ  eqó  Srñ  eqð  `að  VZ÷  T[ð  T[ñ  eqñ  Sró  Jsô  {}÷  {Cò  {Cñ  Zfó  Dgñ  Zfð  UVð  GO÷  EPð  EPñ  Zfñ  Dgó  {hõ  iØ	€&�rˆJØ—N‘NÖ$�j€dˆ5ÙÓ1™�1 6¥§¡§�QˆQ™€8Ð1¼x¿|º|ÈHÐUWÓ?X±,°$°wÐjnÐYcÐdhÑYiØœC ›JÐ':¼3¸u»:ÄcÈ(ÃmÕ;SÐT^Ô_bÐcgÓ_hÐirÐszð  |Eñ  X\ó  F]ñ  X\ð  STð  IM÷  GNð  GNñ  X\ñ  F]ð  _hñ  Zcó  idñ  Zcð  UVô  jmð  noó  jpô  qx÷  q~ò  q~ð  Cð  DHð  IKð  JKð  DLð  MOó  qPò  jPñ  Zcñ  idð  ejô  kr÷  kxò  kxð  y}ð  ~Bð  CEó  kFð  G€6ˆ$ƒ<ñ %ð 	ˆ…^�UÔØÐ Õ!€8Øˆ^Õ˜YÕ'¨Õ-¨iÕ8¸(ÔBÌÐTó  JAð  DAÜˆˆq�	Ð*¨4Ð0Ð2GÐ\fÐguÕ\vÐwzÖ\{ÓH|Ñ\{ÐWXÈ6ÏÈÑ\{ÑH|Ð1}ð  @Rð  gqð  r@õ  gAð  BEö  gFó  SGñ  gFð  bcð  V\÷  T]ð  T]ñ  gFñ  SGð  Hð  J_ð  t~ð  Rõ  tSð  TWö  tXó  `Yñ  tXð  opð  ci÷  ajð  ajñ  tXñ  `Yð  IZð  [ô  \_ð  bhð  inð  orð  hsð  swð  `xõ  \xô  yð _ˆð  _Ðœc #›hÐ'8¸À(È6ÐRcÔdiÔjn×jxÒjxÓjzð  |Cõ  kCð  DEó  eFð  G]ð  `mð  nsð  twð  mxð  x|ð  ^}ð  ~Eð  HNð  OTð  UXð  NYð  Y]ð  F^ñ  _€#ð  `g÷  `nñ  `nð  orô  `sÜˆ5ˆ'�”3�q˜•~Ó&Ð' r¨#¨i­.Ð)9¸¸3¸{Õ;KÐ:LÈFÐSVÐW]ÕS^ÐR_Ð_`ÐaÐbe×bjÑbjñ  koð  `f÷  `lñ  `lô  `nó  koó  coõ  	oð  vz÷  {ð  {ñ) .ð* Ð,Ð->¼sÄ3ÀÕCVÓ?WÐXaÐbiÐjsð  uPð  Q€ô  SVð  Weõ  Se÷  Rqñ  Rqô  rv÷  r|ò  r|ð  }@ð  HIô  rJð  KOõ  rOô  RPØ	€Ü
€QØ€h…K€!�—‘˜_¬T¯[ª[¸¸;½Ó-HÕHÈÕTÔUXÐYZÐ[aÕYbÓUcÕcÐduÕuÐvwÐxõ  wAõ  Að  BWõ  Wô  X[ð  \]ð  ^lõ  \mð  nwõ  \xð  y}õ  \~ð  Hõ  \Ió  XJõ  Jð  K^õ  ^ô  _bð  cdð  esõ  ctð  u~õ  cð  @Dõ  cEð  FOõ  cPó  _Qõ  Qð  Reõ  eô  fið  jkð  lõ  j@ð  AJõ  jKð  LPõ  jQð  R[õ  j\ó  f]õ  ]ð  ^zõ  zô  {~ð  @ð  ATõ  Uð  V`õ  aó  {bõ  bð  cBõ  Bô  CFð  GHð  I\õ  G]ð  ^hõ  Gió  Cjõ  jð  k|õ  |÷  }ñ à	€ÛP€TÙW`ÔaÑW`ÐRSŒÕMÁWÓMÖMÑW`€$ÐaÔgjô  kañ  Y`ó  kaó  haÐbfô  knô  n^ñ  V]ó  n^ó  k^ð  bjô  dgô  gWñ  OVó  gWó  dWð  _cØˆ8�D�6˜ 4¨¥7 )¨9°T¸!µW°I¸YÀtÈAÅwÀiÈyÐY]ÐX^Ð^gÐhpÐgqÐqvÐw{Ðv|ð  }Gð  
Hõ  H‚%ñ Qð `!÷  h!ñ  h!ð  i!p!ð  q!v!ó  w!÷  !ñ  !ð  @"G"ð  H"J"÷  H"O"ñ  H"O"ð  P"U"ó  H"V"ó  W"€ô  Y"\"ð  ]"i"õ  Y"i"÷  X"u"ñ  X"u"ð  v"z"ö  X"{"ùô7 fùÚ	ùó TAùâ^ùò  Rqùò  Gmùò  zXùò  fEùò  Srùò  Dgùò 2ùò F]ùò  idùò
 I}ùò  SGùò  `Yùò bsr   Æ&g(
Çg/
É.g4
É?g4
Ìg:Îg?Î:hÏ%h	ÐhÐ;hÑ&hÒ!hÓhÔ#h"Ô;.h'×4h,Øh1Ùh6äh;Ú__main__)Ú__doc__r   r‡   r�   r¯   Úpathlibr   Únumpyr‘   ÚPILr   r   Údiatom_pilot.phase_hypothesesr   Ú"diatom_pilot.multiplane_hypothesesr   Úr58_focal_controlsr¥   Úr44_score_fieldsr§   Ú__file__ÚresolveÚparentsr‹   r‰   r   r4   rË   Ú__name__rj   r   r   Ú<module>rÙ      si   ðÙ Oß × Ý Û ß Ý @Ý =Û %Û "Ù	ˆ(ƒ^×ÑÓ×%Ñ% aÕ(€¨T°-Õ-?¨Ú Bòò#{"ðH ˆZÔ™žÑr   