Merge branch 'release_26.1' into dev

This commit is contained in:
mvdbeek
2026-10-09 06:00:55 +02:00
16 changed files with 595 additions and 35 deletions
+46 -18
View File
@@ -16,6 +16,26 @@
document.getElementById("gtn-container").style.visibility = "visible";
}
function buttonify(el, activate) {
el.addEventListener("click", activate);
if (el.tagName.toLowerCase() === "a") {
return;
}
// GTN renders tool and workflow buttons as spans, which are not focusable or keyboard operable on their own.
if (!el.hasAttribute("role")) {
el.setAttribute("role", "button");
}
if (!el.hasAttribute("tabindex")) {
el.setAttribute("tabindex", "0");
}
el.addEventListener("keydown", (e) => {
if (e.key === "Enter" || e.key === " ") {
e.preventDefault();
activate();
}
});
}
function getIframeUrl() {
let loc;
try {
@@ -126,6 +146,26 @@
if (!gtnEmbed.contentDocument) {
return;
}
// Sites like Zenodo refuse to be framed, so links leaving the GTN open in a new tab.
gtnEmbed.contentDocument.addEventListener("click", (e) => {
const link = e.target.closest("a[href]");
if (!link || link.closest("[data-tool],[data-workflow]")) {
return;
}
let url;
try {
url = new URL(link.getAttribute("href"), link.baseURI);
} catch (err) {
return;
}
if (url.protocol !== "http:" && url.protocol !== "https:") {
return;
}
if (url.origin !== window.location.origin || !url.pathname.startsWith("/training-material/")) {
link.setAttribute("target", "_blank");
link.relList.add("noopener", "noreferrer");
}
});
// Add the class to the entire GTN page
document
.getElementById("gtn-embed")
@@ -138,15 +178,9 @@
// Buttonify
gtnToolElements.forEach(function (el) {
el.addEventListener("click", function (e) {
let target = e.target;
// Sometimes we get the i or the strong, not the parent.
if (e.target.tagName.toLowerCase() !== "span" && e.target.tagName.toLowerCase() !== "a") {
target = e.target.parentElement;
}
tool_id = target.dataset.tool;
buttonify(el, function () {
// Tool titles can render as nested markup (e.g. <strong><code>), so read the bound element.
const tool_id = el.dataset.tool;
if (tool_id === "upload1" || tool_id === "upload") {
document.getElementById("tool-panel-upload-button").click();
@@ -163,15 +197,9 @@
// Buttonify
gtnWorkflowElements.forEach(function (el) {
el.addEventListener("click", (e) => {
let target = e.target;
// Sometimes we get the i or the strong, not the parent.
if (e.target.tagName.toLowerCase() !== "span" && e.target.tagName.toLowerCase() !== "a") {
target = e.target.parentElement;
}
trs_url = target.dataset.workflow;
buttonify(el, () => {
// The click target can be nested markup inside the button, so read the bound element.
const trs_url = el.dataset.workflow;
Galaxy.router.push({
path: `/workflows/trs_import?trs_url=${encodeURIComponent(trs_url)}&run_form=true`,
});
@@ -16,10 +16,10 @@
<datatype extension="a2m" type="galaxy.datatypes.sequence:Fasta" display_in_upload="true" description="A multiple sequence alignment in A2M format. Each sequence has a single-line description starting with '>', followed by aligned sequence lines. Dots ('.') represent matches to a reference, and hyphens ('-') represent deletions relative to the reference." subclass="true" />
<datatype extension="afg" type="galaxy.datatypes.assembly:Amos" display_in_upload="false"/>
<datatype extension="agp" type="galaxy.datatypes.goldenpath:GoldenPath" display_in_upload="true" description="UCSC GoldenPath assembly"/>
<datatype extension="alto" type="galaxy.datatypes.xml:GenericXml" mimetype="application/xml" subclass="true" description="Analyzed Layout and Text Object" description_url="https://github.com/altoxml/documentation/wiki/Versions"/>
<datatype extension="page.xml" type="galaxy.datatypes.xml:GenericXml" mimetype="application/xml" subclass="true" description="XML format for encoding the layout and text of digitised documents, comparable to ALTO" description_url="https://github.com/PRImA-Research-Lab/PAGE-XML/wiki"/>
<datatype extension="abbyy.xml" type="galaxy.datatypes.xml:GenericXml" mimetype="application/xml" subclass="true" description="ABBYY FineReader XML" description_url="https://support.abbyy.com/hc/en-us/articles/360017270080-Output-XML-document"/>
<datatype extension="hocr" type="galaxy.datatypes.html:GenericHtml" mimetype="text/html" subclass="true" description="HTML format for representing OCR output." description_url="https://kba.github.io/hocr-spec/1.2/"/>
<datatype extension="alto" type="galaxy.datatypes.xml:Alto" mimetype="application/xml" description="Analyzed Layout and Text Object" description_url="https://github.com/altoxml/documentation/wiki/Versions"/>
<datatype extension="page.xml" type="galaxy.datatypes.xml:PageXml" mimetype="application/xml" description="XML format for encoding the layout and text of digitised documents, comparable to ALTO" description_url="https://github.com/PRImA-Research-Lab/PAGE-XML/wiki"/>
<datatype extension="abbyy.xml" type="galaxy.datatypes.xml:AbbyyXml" mimetype="application/xml" description="ABBYY FineReader XML" description_url="https://support.abbyy.com/hc/en-us/articles/360017270080-Output-XML-document"/>
<datatype extension="hocr" type="galaxy.datatypes.text:Hocr" mimetype="text/html" description="HTML format for representing OCR output." description_url="https://kba.github.io/hocr-spec/1.2/"/>
<datatype extension="anvio_cog_profile" type="galaxy.datatypes.anvio:AnvioComposite" display_in_upload="false" subclass="true" />
<datatype extension="anvio_composite" type="galaxy.datatypes.anvio:AnvioComposite" display_in_upload="false" />
<datatype extension="anvio_classifier" type="galaxy.datatypes.data:Data" display_in_upload="false" subclass="true" />
@@ -1428,6 +1428,10 @@
<sniffer type="galaxy.datatypes.proteomics:PEFF"/>
<sniffer type="galaxy.datatypes.molecules:CML"/>
<sniffer type="galaxy.datatypes.triples:Sbol"/>
<sniffer type="galaxy.datatypes.xml:PageXml"/>
<sniffer type="galaxy.datatypes.xml:Alto"/>
<sniffer type="galaxy.datatypes.xml:AbbyyXml"/>
<sniffer type="galaxy.datatypes.text:Hocr"/>
<sniffer type="galaxy.datatypes.xml:GenericXml"/>
<sniffer type="galaxy.datatypes.triples:HDT"/>
<sniffer type="galaxy.datatypes.triples:Turtle"/>
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<document xmlns="http://www.abbyy.com/FineReader_xml/FineReader10-schema-v1.xml" version="1.0" producer="" languages="" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.abbyy.com/FineReader_xml/FineReader10-schema-v1.xml http://www.abbyy.com/FineReader_xml/FineReader10-schema-v1.xml">
<page width="1488" height="2198" resolution="300" originalCoords="1">
<block blockType="Text" l="734" t="280" r="787" b="323"><region><rect l="734" t="280" r="787" b="323"/></region>
<text>
<par align="Center" lineSpacing="1160">
<line baseline="316" l="740" t="286" r="781" b="317"><formatting lang="GermanStandard" ff="Times New Roman" fs="10.5" bold="1">
<charParams l="740" t="287" r="756" b="317" wordFirst="1" wordLeftMost="1" wordFromDictionary="0" wordNormal="0" wordNumeric="1" wordIdentifier="0" charConfidence="100" serifProbability="91" wordPenalty="0" meanStrokeWidth="46">1</charParams>
<charParams l="761" t="286" r="781" b="316" wordFromDictionary="0" wordNormal="0" wordNumeric="1" wordIdentifier="0" charConfidence="44" serifProbability="255" wordPenalty="0" meanStrokeWidth="46">2</charParams></formatting></line></par>
</text>
</block>
</page>
</document>
+20
View File
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<alto xmlns="http://www.loc.gov/standards/alto/ns-v4#">
<Description>
<MeasurementUnit>pixel</MeasurementUnit>
<sourceImageInformation><fileName>sample.png</fileName></sourceImageInformation>
</Description>
<Layout>
<Page ID="page_1" PHYSICAL_IMG_NR="1" WIDTH="800" HEIGHT="600">
<PrintSpace HPOS="50" VPOS="50" WIDTH="700" HEIGHT="70">
<TextBlock ID="block_1" HPOS="50" VPOS="50" WIDTH="700" HEIGHT="70">
<TextLine ID="line_1" HPOS="50" VPOS="50" WIDTH="350" HEIGHT="50">
<String ID="word_1" CONTENT="Hello" HPOS="50" VPOS="50" WIDTH="130" HEIGHT="50" WC="0.99"/>
<SP HPOS="180" VPOS="50" WIDTH="20"/>
<String ID="word_2" CONTENT="Galaxy" HPOS="200" VPOS="50" WIDTH="200" HEIGHT="50" WC="0.98"/>
</TextLine>
</TextBlock>
</PrintSpace>
</Page>
</Layout>
</alto>
+116
View File
@@ -0,0 +1,116 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>
</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta name='ocr-system' content='tesseract 3.03' />
<meta name='ocr-capabilities' content='ocr_page ocr_carea ocr_par ocr_line ocrx_word'/>
</head>
<body>
<div class='ocr_page' id='page_1' title='image "alice_1.png"; bbox 0 0 2488 3507; ppageno 0'>
<div class='ocr_carea' id='block_1_1' title="bbox 470 527 1383 586">
<p class='ocr_par' dir='ltr' id='par_1_1' title="bbox 470 528 1383 585">
<span class='ocr_line' id='line_1_1' title="bbox 470 528 1383 585; baseline 0.005 -5"><span class='ocrx_word' id='word_1_1' title='bbox 470 530 499 580; x_wconf 96' lang='eng'>1</span> <span class='ocrx_word' id='word_1_2' title='bbox 588 528 787 581; x_wconf 91' lang='eng' dir='ltr'>Down</span> <span class='ocrx_word' id='word_1_3' title='bbox 817 529 927 582; x_wconf 88' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_4' title='bbox 959 531 1383 585; x_wconf 89' lang='eng' dir='ltr'>Rabbit-Hole</span>
</span>
</p>
</div>
<div class='ocr_carea' id='block_1_2' title="bbox 449 651 2078 2804">
<p class='ocr_par' dir='ltr' id='par_1_2' title="bbox 462 651 2076 881">
<span class='ocr_line' id='line_1_2' title="bbox 464 651 2074 704; baseline 0.005 -17"><span class='ocrx_word' id='word_1_5' title='bbox 464 651 569 688; x_wconf 86' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_6' title='bbox 591 665 667 688; x_wconf 91' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_7' title='bbox 690 653 896 699; x_wconf 83' lang='eng' dir='ltr'>beginning</span> <span class='ocrx_word' id='word_1_8' title='bbox 917 659 959 690; x_wconf 93' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_9' title='bbox 981 660 1043 700; x_wconf 88' lang='eng' dir='ltr'>get</span> <span class='ocrx_word' id='word_1_10' title='bbox 1066 668 1155 701; x_wconf 89' lang='eng' dir='ltr'>very</span> <span class='ocrx_word' id='word_1_11' title='bbox 1176 657 1274 692; x_wconf 90' lang='eng' dir='ltr'>tired</span> <span class='ocrx_word' id='word_1_12' title='bbox 1296 656 1336 692; x_wconf 87' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_13' title='bbox 1355 659 1489 702; x_wconf 91' lang='eng' dir='ltr'>sitting</span> <span class='ocrx_word' id='word_1_14' title='bbox 1510 658 1561 702; x_wconf 94' lang='eng' dir='ltr'>by</span> <span class='ocrx_word' id='word_1_15' title='bbox 1583 658 1648 694; x_wconf 88' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_16' title='bbox 1671 660 1781 694; x_wconf 82' lang='eng' dir='ltr'>sister</span> <span class='ocrx_word' id='word_1_17' title='bbox 1803 671 1853 694; x_wconf 90' lang='eng' dir='ltr'>on</span> <span class='ocrx_word' id='word_1_18' title='bbox 1874 660 1940 695; x_wconf 85' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_19' title='bbox 1962 660 2074 704; x_wconf 90' lang='eng' dir='ltr'>bank,</span>
</span>
<span class='ocr_line' id='line_1_3' title="bbox 464 711 2076 763; baseline 0.005 -15"><span class='ocrx_word' id='word_1_20' title='bbox 464 711 540 748; x_wconf 92' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_21' title='bbox 557 711 597 748; x_wconf 90' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_22' title='bbox 610 712 750 759; x_wconf 82' lang='eng' dir='ltr'>having</span> <span class='ocrx_word' id='word_1_23' title='bbox 767 713 928 760; x_wconf 88' lang='eng' dir='ltr'>nothing</span> <span class='ocrx_word' id='word_1_24' title='bbox 943 718 985 751; x_wconf 89' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_25' title='bbox 1001 714 1061 751; x_wconf 89' lang='eng' dir='ltr'>do:</span> <span class='ocrx_word' id='word_1_26' title='bbox 1087 727 1179 752; x_wconf 88' lang='eng' dir='ltr'>once</span> <span class='ocrx_word' id='word_1_27' title='bbox 1195 728 1236 752; x_wconf 94' lang='eng' dir='ltr'>or</span> <span class='ocrx_word' id='word_1_28' title='bbox 1251 717 1359 753; x_wconf 87' lang='eng' dir='ltr'>twice</span> <span class='ocrx_word' id='word_1_29' title='bbox 1376 716 1441 753; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_30' title='bbox 1458 716 1535 754; x_wconf 88' lang='eng' dir='ltr'>had</span> <span class='ocrx_word' id='word_1_31' title='bbox 1551 718 1698 763; x_wconf 92' lang='eng' dir='ltr'>peeped</span> <span class='ocrx_word' id='word_1_32' title='bbox 1715 719 1795 755; x_wconf 94' lang='eng' dir='ltr'>into</span> <span class='ocrx_word' id='word_1_33' title='bbox 1811 718 1878 755; x_wconf 86' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_34' title='bbox 1894 719 1995 756; x_wconf 89' lang='eng' dir='ltr'>book</span> <span class='ocrx_word' id='word_1_35' title='bbox 2011 719 2076 756; x_wconf 89' lang='eng' dir='ltr'>her</span>
</span>
<span class='ocr_line' id='line_1_4' title="bbox 463 773 2075 823; baseline 0.005 -16"><span class='ocrx_word' id='word_1_36' title='bbox 463 773 572 807; x_wconf 84' lang='eng' dir='ltr'>sister</span> <span class='ocrx_word' id='word_1_37' title='bbox 589 784 665 808; x_wconf 89' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_38' title='bbox 682 773 850 819; x_wconf 84' lang='eng' dir='ltr'>reading,</span> <span class='ocrx_word' id='word_1_39' title='bbox 869 773 939 810; x_wconf 92' lang='eng' dir='ltr'>but</span> <span class='ocrx_word' id='word_1_40' title='bbox 958 775 987 810; x_wconf 90' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_41' title='bbox 1005 774 1081 811; x_wconf 86' lang='eng' dir='ltr'>had</span> <span class='ocrx_word' id='word_1_42' title='bbox 1098 786 1147 811; x_wconf 90' lang='eng' dir='ltr'>no</span> <span class='ocrx_word' id='word_1_43' title='bbox 1164 776 1328 820; x_wconf 87' lang='eng' dir='ltr'>pictures</span> <span class='ocrx_word' id='word_1_44' title='bbox 1346 788 1386 812; x_wconf 93' lang='eng' dir='ltr'>or</span> <span class='ocrx_word' id='word_1_45' title='bbox 1404 778 1685 814; x_wconf 84' lang='eng' dir='ltr'>conversations</span> <span class='ocrx_word' id='word_1_46' title='bbox 1703 779 1742 814; x_wconf 93' lang='eng' dir='ltr'>in</span> <span class='ocrx_word' id='word_1_47' title='bbox 1759 779 1800 823; x_wconf 91' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_48' title='bbox 1822 778 1910 815; x_wconf 90' lang='eng' dir='ltr'>‘and</span> <span class='ocrx_word' id='word_1_49' title='bbox 1926 778 2027 815; x_wconf 87' lang='eng' dir='ltr'>what</span> <span class='ocrx_word' id='word_1_50' title='bbox 2046 780 2075 816; x_wconf 89' lang='eng' dir='ltr'>is</span>
</span>
<span class='ocr_line' id='line_1_5' title="bbox 462 832 1915 881; baseline 0.006 -15"><span class='ocrx_word' id='word_1_51' title='bbox 462 832 528 866; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_52' title='bbox 547 844 612 867; x_wconf 91' lang='eng' dir='ltr'>use</span> <span class='ocrx_word' id='word_1_53' title='bbox 631 832 672 867; x_wconf 86' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_54' title='bbox 687 845 711 867; x_wconf 93' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_55' title='bbox 728 833 856 877; x_wconf 90' lang='eng' dir='ltr'>book,’</span> <span class='ocrx_word' id='word_1_56' title='bbox 876 834 1039 879; x_wconf 90' lang='eng' dir='ltr'>thought</span> <span class='ocrx_word' id='word_1_57' title='bbox 1058 834 1163 870; x_wconf 84' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_58' title='bbox 1183 835 1355 871; x_wconf 84' lang='eng' dir='ltr'>‘Without</span> <span class='ocrx_word' id='word_1_59' title='bbox 1374 838 1540 881; x_wconf 89' lang='eng' dir='ltr'>pictures</span> <span class='ocrx_word' id='word_1_60' title='bbox 1558 849 1600 872; x_wconf 90' lang='eng' dir='ltr'>or</span> <span class='ocrx_word' id='word_1_61' title='bbox 1618 838 1915 874; x_wconf 80' lang='eng' dir='ltr'>conversation?’</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_3' title="bbox 461 891 2076 1124">
<span class='ocr_line' id='line_1_6' title="bbox 536 891 2074 943; baseline 0.005 -16"><span class='ocrx_word' id='word_1_62' title='bbox 536 891 585 927; x_wconf 91' lang='eng' dir='ltr'>So</span> <span class='ocrx_word' id='word_1_63' title='bbox 602 893 668 927; x_wconf 93' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_64' title='bbox 685 905 761 928; x_wconf 89' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_65' title='bbox 779 894 1016 938; x_wconf 90' lang='eng' dir='ltr'>considering</span> <span class='ocrx_word' id='word_1_66' title='bbox 1033 896 1071 929; x_wconf 91' lang='eng' dir='ltr'>in</span> <span class='ocrx_word' id='word_1_67' title='bbox 1088 895 1153 930; x_wconf 89' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_68' title='bbox 1170 907 1253 930; x_wconf 92' lang='eng' dir='ltr'>own</span> <span class='ocrx_word' id='word_1_69' title='bbox 1270 896 1375 931; x_wconf 91' lang='eng' dir='ltr'>mind</span> <span class='ocrx_word' id='word_1_70' title='bbox 1396 894 1453 943; x_wconf 90' lang='eng' dir='ltr'>(as</span> <span class='ocrx_word' id='word_1_71' title='bbox 1469 897 1551 932; x_wconf 90' lang='eng' dir='ltr'>well</span> <span class='ocrx_word' id='word_1_72' title='bbox 1569 909 1609 932; x_wconf 88' lang='eng' dir='ltr'>as</span> <span class='ocrx_word' id='word_1_73' title='bbox 1627 898 1693 932; x_wconf 92' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_74' title='bbox 1711 898 1833 941; x_wconf 87' lang='eng' dir='ltr'>could,</span> <span class='ocrx_word' id='word_1_75' title='bbox 1853 898 1909 933; x_wconf 89' lang='eng' dir='ltr'>for</span> <span class='ocrx_word' id='word_1_76' title='bbox 1925 899 1991 934; x_wconf 91' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_77' title='bbox 2008 899 2074 934; x_wconf 91' lang='eng' dir='ltr'>hot</span>
</span>
<span class='ocr_line' id='line_1_7' title="bbox 462 951 2076 1004; baseline 0.005 -17"><span class='ocrx_word' id='word_1_78' title='bbox 462 951 535 996; x_wconf 92' lang='eng' dir='ltr'>day</span> <span class='ocrx_word' id='word_1_79' title='bbox 553 951 665 988; x_wconf 91' lang='eng' dir='ltr'>made</span> <span class='ocrx_word' id='word_1_80' title='bbox 682 952 748 988; x_wconf 90' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_81' title='bbox 765 952 835 989; x_wconf 89' lang='eng' dir='ltr'>feel</span> <span class='ocrx_word' id='word_1_82' title='bbox 853 965 941 998; x_wconf 91' lang='eng' dir='ltr'>very</span> <span class='ocrx_word' id='word_1_83' title='bbox 959 953 1083 999; x_wconf 90' lang='eng' dir='ltr'>sleepy</span> <span class='ocrx_word' id='word_1_84' title='bbox 1101 954 1176 991; x_wconf 90' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_85' title='bbox 1193 952 1353 1003; x_wconf 87' lang='eng' dir='ltr'>stupid),</span> <span class='ocrx_word' id='word_1_86' title='bbox 1372 955 1541 992; x_wconf 90' lang='eng' dir='ltr'>whether</span> <span class='ocrx_word' id='word_1_87' title='bbox 1557 956 1624 993; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_88' title='bbox 1641 957 1813 1002; x_wconf 87' lang='eng' dir='ltr'>pleasure</span> <span class='ocrx_word' id='word_1_89' title='bbox 1830 957 1871 994; x_wconf 92' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_90' title='bbox 1885 958 2037 1004; x_wconf 90' lang='eng' dir='ltr'>making</span> <span class='ocrx_word' id='word_1_91' title='bbox 2054 971 2076 995; x_wconf 92' lang='eng' dir='ltr'>a</span>
</span>
<span class='ocr_line' id='line_1_8' title="bbox 462 1011 2072 1064; baseline 0.006 -17"><span class='ocrx_word' id='word_1_92' title='bbox 462 1011 699 1058; x_wconf 91' lang='eng' dir='ltr'>daisy-chain</span> <span class='ocrx_word' id='word_1_93' title='bbox 715 1012 840 1049; x_wconf 91' lang='eng' dir='ltr'>would</span> <span class='ocrx_word' id='word_1_94' title='bbox 856 1012 904 1050; x_wconf 91' lang='eng' dir='ltr'>be</span> <span class='ocrx_word' id='word_1_95' title='bbox 920 1013 1041 1050; x_wconf 91' lang='eng' dir='ltr'>worth</span> <span class='ocrx_word' id='word_1_96' title='bbox 1056 1014 1122 1051; x_wconf 89' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_97' title='bbox 1137 1014 1286 1052; x_wconf 90' lang='eng' dir='ltr'>trouble</span> <span class='ocrx_word' id='word_1_98' title='bbox 1302 1014 1343 1052; x_wconf 92' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_99' title='bbox 1355 1017 1502 1062; x_wconf 88' lang='eng' dir='ltr'>getting</span> <span class='ocrx_word' id='word_1_100' title='bbox 1518 1029 1570 1062; x_wconf 93' lang='eng' dir='ltr'>up</span> <span class='ocrx_word' id='word_1_101' title='bbox 1587 1016 1663 1054; x_wconf 90' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_102' title='bbox 1679 1017 1831 1064; x_wconf 89' lang='eng' dir='ltr'>picking</span> <span class='ocrx_word' id='word_1_103' title='bbox 1845 1018 1911 1055; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_104' title='bbox 1927 1018 2072 1064; x_wconf 85' lang='eng' dir='ltr'>daisies,</span>
</span>
<span class='ocr_line' id='line_1_9' title="bbox 461 1072 1816 1124; baseline 0.005 -17"><span class='ocrx_word' id='word_1_105' title='bbox 461 1072 571 1108; x_wconf 92' lang='eng' dir='ltr'>when</span> <span class='ocrx_word' id='word_1_106' title='bbox 589 1073 776 1119; x_wconf 90' lang='eng' dir='ltr'>suddenly</span> <span class='ocrx_word' id='word_1_107' title='bbox 795 1086 818 1109; x_wconf 93' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_108' title='bbox 835 1074 965 1110; x_wconf 90' lang='eng' dir='ltr'>White</span> <span class='ocrx_word' id='word_1_109' title='bbox 984 1074 1126 1111; x_wconf 90' lang='eng' dir='ltr'>Rabbit</span> <span class='ocrx_word' id='word_1_110' title='bbox 1145 1075 1237 1111; x_wconf 91' lang='eng' dir='ltr'>with</span> <span class='ocrx_word' id='word_1_111' title='bbox 1255 1076 1346 1121; x_wconf 90' lang='eng' dir='ltr'>pink</span> <span class='ocrx_word' id='word_1_112' title='bbox 1364 1088 1449 1122; x_wconf 91' lang='eng' dir='ltr'>eyes</span> <span class='ocrx_word' id='word_1_113' title='bbox 1466 1089 1536 1113; x_wconf 94' lang='eng' dir='ltr'>ran</span> <span class='ocrx_word' id='word_1_114' title='bbox 1554 1077 1653 1113; x_wconf 90' lang='eng' dir='ltr'>close</span> <span class='ocrx_word' id='word_1_115' title='bbox 1671 1077 1721 1124; x_wconf 93' lang='eng' dir='ltr'>by</span> <span class='ocrx_word' id='word_1_116' title='bbox 1740 1078 1816 1114; x_wconf 92' lang='eng' dir='ltr'>her.</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_4' title="bbox 455 1133 2074 1722">
<span class='ocr_line' id='line_1_10' title="bbox 534 1133 2074 1182; baseline 0.005 -14"><span class='ocrx_word' id='word_1_117' title='bbox 534 1133 657 1169; x_wconf 92' lang='eng' dir='ltr'>There</span> <span class='ocrx_word' id='word_1_118' title='bbox 673 1146 749 1169; x_wconf 90' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_119' title='bbox 766 1134 927 1180; x_wconf 88' lang='eng' dir='ltr'>nothing</span> <span class='ocrx_word' id='word_1_120' title='bbox 944 1147 985 1171; x_wconf 91' lang='eng' dir='ltr'>so</span> <span class='ocrx_word' id='word_1_121' title='bbox 1001 1135 1137 1172; x_wconf 87' lang='eng' dir='ltr'>VERY</span> <span class='ocrx_word' id='word_1_122' title='bbox 1152 1136 1383 1173; x_wconf 87' lang='eng' dir='ltr'>remarkable</span> <span class='ocrx_word' id='word_1_123' title='bbox 1400 1138 1438 1173; x_wconf 90' lang='eng' dir='ltr'>in</span> <span class='ocrx_word' id='word_1_124' title='bbox 1453 1137 1553 1182; x_wconf 87' lang='eng' dir='ltr'>that;</span> <span class='ocrx_word' id='word_1_125' title='bbox 1572 1150 1641 1174; x_wconf 92' lang='eng' dir='ltr'>nor</span> <span class='ocrx_word' id='word_1_126' title='bbox 1658 1138 1724 1174; x_wconf 92' lang='eng' dir='ltr'>did</span> <span class='ocrx_word' id='word_1_127' title='bbox 1740 1138 1846 1175; x_wconf 89' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_128' title='bbox 1861 1139 1971 1175; x_wconf 88' lang='eng' dir='ltr'>think</span> <span class='ocrx_word' id='word_1_129' title='bbox 1987 1141 2016 1176; x_wconf 94' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_130' title='bbox 2033 1153 2074 1176; x_wconf 93' lang='eng' dir='ltr'>so</span>
</span>
<span class='ocr_line' id='line_1_11' title="bbox 461 1192 2074 1244; baseline 0.005 -15"><span class='ocrx_word' id='word_1_131' title='bbox 461 1192 597 1230; x_wconf 83' lang='eng' dir='ltr'>VERY</span> <span class='ocrx_word' id='word_1_132' title='bbox 617 1193 729 1230; x_wconf 90' lang='eng' dir='ltr'>much</span> <span class='ocrx_word' id='word_1_133' title='bbox 749 1198 817 1230; x_wconf 88' lang='eng' dir='ltr'>out</span> <span class='ocrx_word' id='word_1_134' title='bbox 838 1194 879 1230; x_wconf 89' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_135' title='bbox 895 1194 962 1231; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_136' title='bbox 981 1207 1062 1241; x_wconf 93' lang='eng' dir='ltr'>way</span> <span class='ocrx_word' id='word_1_137' title='bbox 1081 1199 1123 1232; x_wconf 92' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_138' title='bbox 1143 1195 1232 1232; x_wconf 91' lang='eng' dir='ltr'>hear</span> <span class='ocrx_word' id='word_1_139' title='bbox 1251 1196 1317 1233; x_wconf 91' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_140' title='bbox 1338 1197 1480 1234; x_wconf 88' lang='eng' dir='ltr'>Rabbit</span> <span class='ocrx_word' id='word_1_141' title='bbox 1502 1210 1568 1244; x_wconf 91' lang='eng' dir='ltr'>say</span> <span class='ocrx_word' id='word_1_142' title='bbox 1587 1202 1629 1235; x_wconf 90' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_143' title='bbox 1650 1198 1761 1244; x_wconf 87' lang='eng' dir='ltr'>itself,</span> <span class='ocrx_word' id='word_1_144' title='bbox 1786 1198 1861 1236; x_wconf 86' lang='eng' dir='ltr'>‘Oh</span> <span class='ocrx_word' id='word_1_145' title='bbox 1881 1199 1980 1236; x_wconf 91' lang='eng' dir='ltr'>dear!</span> <span class='ocrx_word' id='word_1_146' title='bbox 2013 1199 2074 1237; x_wconf 93' lang='eng' dir='ltr'>Oh</span>
</span>
<span class='ocr_line' id='line_1_12' title="bbox 460 1252 2073 1302; baseline 0.006 -15"><span class='ocrx_word' id='word_1_147' title='bbox 460 1252 561 1288; x_wconf 90' lang='eng' dir='ltr'>dear!</span> <span class='ocrx_word' id='word_1_148' title='bbox 596 1253 610 1288; x_wconf 94' lang='eng' dir='ltr'>I</span> <span class='ocrx_word' id='word_1_149' title='bbox 631 1253 728 1289; x_wconf 91' lang='eng' dir='ltr'>shall</span> <span class='ocrx_word' id='word_1_150' title='bbox 748 1254 796 1289; x_wconf 92' lang='eng' dir='ltr'>be</span> <span class='ocrx_word' id='word_1_151' title='bbox 817 1254 919 1290; x_wconf 86' lang='eng' dir='ltr'>late!’</span> <span class='ocrx_word' id='word_1_152' title='bbox 955 1252 1079 1301; x_wconf 90' lang='eng' dir='ltr'>(when</span> <span class='ocrx_word' id='word_1_153' title='bbox 1100 1256 1164 1291; x_wconf 92' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_154' title='bbox 1185 1256 1347 1301; x_wconf 91' lang='eng' dir='ltr'>thought</span> <span class='ocrx_word' id='word_1_155' title='bbox 1368 1258 1398 1292; x_wconf 93' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_156' title='bbox 1419 1269 1505 1293; x_wconf 91' lang='eng' dir='ltr'>over</span> <span class='ocrx_word' id='word_1_157' title='bbox 1526 1257 1759 1302; x_wconf 85' lang='eng' dir='ltr'>afterwards,</span> <span class='ocrx_word' id='word_1_158' title='bbox 1783 1260 1812 1294; x_wconf 91' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_159' title='bbox 1834 1260 2012 1295; x_wconf 89' lang='eng' dir='ltr'>occurred</span> <span class='ocrx_word' id='word_1_160' title='bbox 2032 1264 2073 1296; x_wconf 92' lang='eng' dir='ltr'>to</span>
</span>
<span class='ocr_line' id='line_1_13' title="bbox 460 1311 2073 1360; baseline 0.005 -13"><span class='ocrx_word' id='word_1_161' title='bbox 460 1311 525 1347; x_wconf 89' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_162' title='bbox 546 1312 632 1348; x_wconf 89' lang='eng' dir='ltr'>that</span> <span class='ocrx_word' id='word_1_163' title='bbox 655 1312 721 1348; x_wconf 90' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_164' title='bbox 742 1313 860 1358; x_wconf 91' lang='eng' dir='ltr'>ought</span> <span class='ocrx_word' id='word_1_165' title='bbox 881 1318 923 1350; x_wconf 93' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_166' title='bbox 944 1314 1037 1350; x_wconf 91' lang='eng' dir='ltr'>have</span> <span class='ocrx_word' id='word_1_167' title='bbox 1058 1315 1257 1351; x_wconf 91' lang='eng' dir='ltr'>wondered</span> <span class='ocrx_word' id='word_1_168' title='bbox 1277 1320 1316 1352; x_wconf 91' lang='eng' dir='ltr'>at</span> <span class='ocrx_word' id='word_1_169' title='bbox 1337 1316 1426 1360; x_wconf 91' lang='eng' dir='ltr'>this,</span> <span class='ocrx_word' id='word_1_170' title='bbox 1449 1316 1519 1353; x_wconf 95' lang='eng' dir='ltr'>but</span> <span class='ocrx_word' id='word_1_171' title='bbox 1542 1321 1581 1353; x_wconf 90' lang='eng' dir='ltr'>at</span> <span class='ocrx_word' id='word_1_172' title='bbox 1603 1317 1670 1353; x_wconf 91' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_173' title='bbox 1690 1319 1784 1354; x_wconf 91' lang='eng' dir='ltr'>time</span> <span class='ocrx_word' id='word_1_174' title='bbox 1805 1320 1834 1354; x_wconf 92' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_175' title='bbox 1856 1318 1905 1354; x_wconf 91' lang='eng' dir='ltr'>all</span> <span class='ocrx_word' id='word_1_176' title='bbox 1925 1319 2073 1355; x_wconf 87' lang='eng' dir='ltr'>seemed</span>
</span>
<span class='ocr_line' id='line_1_14' title="bbox 459 1369 2072 1422; baseline 0.006 -15"><span class='ocrx_word' id='word_1_177' title='bbox 459 1373 564 1417; x_wconf 89' lang='eng' dir='ltr'>quite</span> <span class='ocrx_word' id='word_1_178' title='bbox 585 1369 769 1420; x_wconf 90' lang='eng' dir='ltr'>natural);</span> <span class='ocrx_word' id='word_1_179' title='bbox 793 1372 863 1409; x_wconf 92' lang='eng' dir='ltr'>but</span> <span class='ocrx_word' id='word_1_180' title='bbox 885 1373 995 1410; x_wconf 90' lang='eng' dir='ltr'>when</span> <span class='ocrx_word' id='word_1_181' title='bbox 1014 1374 1080 1411; x_wconf 89' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_182' title='bbox 1102 1374 1243 1411; x_wconf 88' lang='eng' dir='ltr'>Rabbit</span> <span class='ocrx_word' id='word_1_183' title='bbox 1266 1375 1432 1422; x_wconf 89' lang='eng' dir='ltr'>actually</span> <span class='ocrx_word' id='word_1_184' title='bbox 1452 1375 1599 1414; x_wconf 91' lang='eng' dir='ltr'>TOOK</span> <span class='ocrx_word' id='word_1_185' title='bbox 1620 1376 1655 1413; x_wconf 89' lang='eng' dir='ltr'><strong>A</strong></span> <span class='ocrx_word' id='word_1_186' title='bbox 1675 1376 1857 1415; x_wconf 88' lang='eng' dir='ltr'>WATCH</span> <span class='ocrx_word' id='word_1_187' title='bbox 1880 1377 1985 1415; x_wconf 90' lang='eng' dir='ltr'>OUT</span> <span class='ocrx_word' id='word_1_188' title='bbox 2006 1378 2072 1416; x_wconf 90' lang='eng' dir='ltr'>OF</span>
</span>
<span class='ocr_line' id='line_1_15' title="bbox 459 1431 2071 1483; baseline 0.006 -17"><span class='ocrx_word' id='word_1_189' title='bbox 459 1431 535 1467; x_wconf 90' lang='eng' dir='ltr'>ITS</span> <span class='ocrx_word' id='word_1_190' title='bbox 555 1431 871 1468; x_wconf 88' lang='eng' dir='ltr'>WAISTCOAT—</span> <span class='ocrx_word' id='word_1_191' title='bbox 893 1433 1113 1479; x_wconf 88' lang='eng' dir='ltr'>POCKET,</span> <span class='ocrx_word' id='word_1_192' title='bbox 1135 1435 1211 1470; x_wconf 90' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_193' title='bbox 1230 1435 1364 1471; x_wconf 92' lang='eng' dir='ltr'>looked</span> <span class='ocrx_word' id='word_1_194' title='bbox 1383 1440 1423 1472; x_wconf 91' lang='eng' dir='ltr'>at</span> <span class='ocrx_word' id='word_1_195' title='bbox 1443 1438 1485 1481; x_wconf 88' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_196' title='bbox 1508 1437 1584 1472; x_wconf 90' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_197' title='bbox 1603 1437 1697 1473; x_wconf 90' lang='eng' dir='ltr'>then</span> <span class='ocrx_word' id='word_1_198' title='bbox 1717 1437 1868 1474; x_wconf 90' lang='eng' dir='ltr'>hurried</span> <span class='ocrx_word' id='word_1_199' title='bbox 1887 1450 1947 1483; x_wconf 92' lang='eng' dir='ltr'>on,</span> <span class='ocrx_word' id='word_1_200' title='bbox 1969 1438 2071 1475; x_wconf 88' lang='eng' dir='ltr'>Alice</span>
</span>
<span class='ocr_line' id='line_1_16' title="bbox 459 1493 2071 1537; baseline 0.005 -11"><span class='ocrx_word' id='word_1_201' title='bbox 459 1493 606 1527; x_wconf 89' lang='eng' dir='ltr'>started</span> <span class='ocrx_word' id='word_1_202' title='bbox 625 1497 667 1528; x_wconf 91' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_203' title='bbox 687 1493 753 1528; x_wconf 90' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_204' title='bbox 773 1493 860 1537; x_wconf 87' lang='eng' dir='ltr'>feet,</span> <span class='ocrx_word' id='word_1_205' title='bbox 882 1494 938 1529; x_wconf 91' lang='eng' dir='ltr'>for</span> <span class='ocrx_word' id='word_1_206' title='bbox 958 1496 987 1529; x_wconf 90' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_207' title='bbox 1007 1494 1152 1530; x_wconf 91' lang='eng' dir='ltr'>flashed</span> <span class='ocrx_word' id='word_1_208' title='bbox 1171 1508 1295 1531; x_wconf 91' lang='eng' dir='ltr'>across</span> <span class='ocrx_word' id='word_1_209' title='bbox 1315 1496 1380 1531; x_wconf 92' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_210' title='bbox 1400 1497 1506 1532; x_wconf 93' lang='eng' dir='ltr'>mind</span> <span class='ocrx_word' id='word_1_211' title='bbox 1525 1497 1612 1532; x_wconf 92' lang='eng' dir='ltr'>that</span> <span class='ocrx_word' id='word_1_212' title='bbox 1633 1498 1699 1533; x_wconf 93' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_213' title='bbox 1719 1498 1796 1533; x_wconf 94' lang='eng' dir='ltr'>had</span> <span class='ocrx_word' id='word_1_214' title='bbox 1816 1511 1926 1534; x_wconf 91' lang='eng' dir='ltr'>never</span> <span class='ocrx_word' id='word_1_215' title='bbox 1946 1499 2071 1535; x_wconf 91' lang='eng' dir='ltr'>before</span>
</span>
<span class='ocr_line' id='line_1_17' title="bbox 459 1552 2072 1604; baseline 0.005 -16"><span class='ocrx_word' id='word_1_216' title='bbox 459 1564 545 1588; x_wconf 88' lang='eng' dir='ltr'>seen</span> <span class='ocrx_word' id='word_1_217' title='bbox 562 1564 585 1588; x_wconf 88' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_218' title='bbox 599 1552 727 1589; x_wconf 88' lang='eng' dir='ltr'>rabbit</span> <span class='ocrx_word' id='word_1_219' title='bbox 744 1553 838 1590; x_wconf 91' lang='eng' dir='ltr'>with</span> <span class='ocrx_word' id='word_1_220' title='bbox 853 1553 973 1591; x_wconf 90' lang='eng' dir='ltr'>either</span> <span class='ocrx_word' id='word_1_221' title='bbox 989 1566 1012 1591; x_wconf 92' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_222' title='bbox 1026 1555 1388 1601; x_wconf 87' lang='eng' dir='ltr'>waistcoat-pocket,</span> <span class='ocrx_word' id='word_1_223' title='bbox 1407 1569 1448 1593; x_wconf 93' lang='eng' dir='ltr'>or</span> <span class='ocrx_word' id='word_1_224' title='bbox 1464 1569 1487 1593; x_wconf 93' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_225' title='bbox 1500 1557 1624 1594; x_wconf 88' lang='eng' dir='ltr'>watch</span> <span class='ocrx_word' id='word_1_226' title='bbox 1639 1561 1681 1594; x_wconf 91' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_227' title='bbox 1696 1557 1785 1595; x_wconf 90' lang='eng' dir='ltr'>take</span> <span class='ocrx_word' id='word_1_228' title='bbox 1801 1563 1868 1595; x_wconf 93' lang='eng' dir='ltr'>out</span> <span class='ocrx_word' id='word_1_229' title='bbox 1885 1558 1925 1596; x_wconf 92' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_230' title='bbox 1937 1560 1977 1604; x_wconf 85' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_231' title='bbox 1996 1559 2072 1596; x_wconf 90' lang='eng' dir='ltr'>and</span>
</span>
<span class='ocr_line' id='line_1_18' title="bbox 458 1612 2070 1663; baseline 0.005 -16"><span class='ocrx_word' id='word_1_232' title='bbox 458 1612 622 1657; x_wconf 90' lang='eng' dir='ltr'>burning</span> <span class='ocrx_word' id='word_1_233' title='bbox 641 1613 734 1648; x_wconf 86' lang='eng' dir='ltr'>with</span> <span class='ocrx_word' id='word_1_234' title='bbox 754 1615 941 1659; x_wconf 90' lang='eng' dir='ltr'>curiosity,</span> <span class='ocrx_word' id='word_1_235' title='bbox 963 1614 1029 1650; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_236' title='bbox 1047 1627 1116 1650; x_wconf 91' lang='eng' dir='ltr'>ran</span> <span class='ocrx_word' id='word_1_237' title='bbox 1135 1627 1259 1651; x_wconf 89' lang='eng' dir='ltr'>across</span> <span class='ocrx_word' id='word_1_238' title='bbox 1278 1616 1343 1652; x_wconf 91' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_239' title='bbox 1362 1616 1450 1652; x_wconf 91' lang='eng' dir='ltr'>field</span> <span class='ocrx_word' id='word_1_240' title='bbox 1469 1616 1566 1653; x_wconf 90' lang='eng' dir='ltr'>after</span> <span class='ocrx_word' id='word_1_241' title='bbox 1585 1619 1627 1661; x_wconf 89' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_242' title='bbox 1649 1618 1726 1654; x_wconf 92' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_243' title='bbox 1746 1618 1978 1663; x_wconf 87' lang='eng' dir='ltr'>fortunately</span> <span class='ocrx_word' id='word_1_244' title='bbox 1996 1632 2070 1655; x_wconf 93' lang='eng' dir='ltr'>was</span>
</span>
<span class='ocr_line' id='line_1_19' title="bbox 455 1671 1894 1722; baseline 0.005 -17"><span class='ocrx_word' id='word_1_245' title='bbox 455 1671 534 1715; x_wconf 89' lang='eng' dir='ltr'>just</span> <span class='ocrx_word' id='word_1_246' title='bbox 554 1672 593 1705; x_wconf 89' lang='eng' dir='ltr'>in</span> <span class='ocrx_word' id='word_1_247' title='bbox 610 1672 705 1706; x_wconf 90' lang='eng' dir='ltr'>time</span> <span class='ocrx_word' id='word_1_248' title='bbox 722 1675 764 1706; x_wconf 90' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_249' title='bbox 783 1683 844 1707; x_wconf 89' lang='eng' dir='ltr'>see</span> <span class='ocrx_word' id='word_1_250' title='bbox 862 1673 891 1707; x_wconf 92' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_251' title='bbox 911 1683 988 1717; x_wconf 94' lang='eng' dir='ltr'>pop</span> <span class='ocrx_word' id='word_1_252' title='bbox 1007 1672 1117 1708; x_wconf 91' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_253' title='bbox 1135 1684 1158 1709; x_wconf 92' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_254' title='bbox 1175 1673 1275 1719; x_wconf 90' lang='eng' dir='ltr'>large</span> <span class='ocrx_word' id='word_1_255' title='bbox 1292 1674 1523 1711; x_wconf 90' lang='eng' dir='ltr'>rabbit-hole</span> <span class='ocrx_word' id='word_1_256' title='bbox 1541 1675 1662 1711; x_wconf 92' lang='eng' dir='ltr'>under</span> <span class='ocrx_word' id='word_1_257' title='bbox 1679 1676 1746 1712; x_wconf 93' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_258' title='bbox 1765 1676 1894 1722; x_wconf 91' lang='eng' dir='ltr'>hedge.</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_5' title="bbox 458 1730 2071 1838">
<span class='ocr_line' id='line_1_20' title="bbox 531 1730 2071 1783; baseline 0.005 -18"><span class='ocrx_word' id='word_1_259' title='bbox 531 1730 573 1765; x_wconf 93' lang='eng' dir='ltr'>In</span> <span class='ocrx_word' id='word_1_260' title='bbox 591 1731 752 1766; x_wconf 90' lang='eng' dir='ltr'>another</span> <span class='ocrx_word' id='word_1_261' title='bbox 769 1736 939 1767; x_wconf 88' lang='eng' dir='ltr'>moment</span> <span class='ocrx_word' id='word_1_262' title='bbox 958 1732 1067 1768; x_wconf 91' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_263' title='bbox 1084 1738 1180 1769; x_wconf 90' lang='eng' dir='ltr'>went</span> <span class='ocrx_word' id='word_1_264' title='bbox 1199 1733 1303 1770; x_wconf 88' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_265' title='bbox 1321 1734 1416 1770; x_wconf 85' lang='eng' dir='ltr'>after</span> <span class='ocrx_word' id='word_1_266' title='bbox 1434 1736 1475 1779; x_wconf 93' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_267' title='bbox 1495 1747 1607 1771; x_wconf 92' lang='eng' dir='ltr'>never</span> <span class='ocrx_word' id='word_1_268' title='bbox 1625 1748 1718 1771; x_wconf 91' lang='eng' dir='ltr'>once</span> <span class='ocrx_word' id='word_1_269' title='bbox 1736 1737 1972 1783; x_wconf 88' lang='eng' dir='ltr'>considering</span> <span class='ocrx_word' id='word_1_270' title='bbox 1988 1737 2071 1773; x_wconf 92' lang='eng' dir='ltr'>how</span>
</span>
<span class='ocr_line' id='line_1_21' title="bbox 458 1790 1259 1838; baseline 0.006 -14"><span class='ocrx_word' id='word_1_271' title='bbox 458 1791 496 1824; x_wconf 93' lang='eng' dir='ltr'>in</span> <span class='ocrx_word' id='word_1_272' title='bbox 514 1790 580 1825; x_wconf 88' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_273' title='bbox 598 1791 714 1826; x_wconf 90' lang='eng' dir='ltr'>world</span> <span class='ocrx_word' id='word_1_274' title='bbox 733 1791 799 1827; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_275' title='bbox 817 1804 893 1827; x_wconf 91' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_276' title='bbox 911 1796 953 1827; x_wconf 94' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_277' title='bbox 971 1797 1032 1837; x_wconf 88' lang='eng' dir='ltr'>get</span> <span class='ocrx_word' id='word_1_278' title='bbox 1052 1797 1119 1828; x_wconf 84' lang='eng' dir='ltr'>out</span> <span class='ocrx_word' id='word_1_279' title='bbox 1138 1795 1259 1838; x_wconf 90' lang='eng' dir='ltr'>again.</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_6' title="bbox 457 1850 2069 2022">
<span class='ocr_line' id='line_1_22' title="bbox 530 1850 2069 1902; baseline 0.005 -16"><span class='ocrx_word' id='word_1_280' title='bbox 530 1850 611 1886; x_wconf 91' lang='eng' dir='ltr'>The</span> <span class='ocrx_word' id='word_1_281' title='bbox 634 1850 866 1888; x_wconf 86' lang='eng' dir='ltr'>rabbit-hole</span> <span class='ocrx_word' id='word_1_282' title='bbox 889 1856 986 1888; x_wconf 92' lang='eng' dir='ltr'>went</span> <span class='ocrx_word' id='word_1_283' title='bbox 1011 1853 1170 1899; x_wconf 89' lang='eng' dir='ltr'>straight</span> <span class='ocrx_word' id='word_1_284' title='bbox 1194 1866 1243 1889; x_wconf 91' lang='eng' dir='ltr'>on</span> <span class='ocrx_word' id='word_1_285' title='bbox 1265 1854 1336 1890; x_wconf 92' lang='eng' dir='ltr'>like</span> <span class='ocrx_word' id='word_1_286' title='bbox 1359 1867 1382 1890; x_wconf 90' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_287' title='bbox 1403 1855 1537 1891; x_wconf 90' lang='eng' dir='ltr'>tunnel</span> <span class='ocrx_word' id='word_1_288' title='bbox 1561 1855 1617 1891; x_wconf 90' lang='eng' dir='ltr'>for</span> <span class='ocrx_word' id='word_1_289' title='bbox 1640 1868 1744 1892; x_wconf 88' lang='eng' dir='ltr'>some</span> <span class='ocrx_word' id='word_1_290' title='bbox 1766 1869 1854 1902; x_wconf 91' lang='eng' dir='ltr'>way,</span> <span class='ocrx_word' id='word_1_291' title='bbox 1880 1857 1956 1893; x_wconf 88' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_292' title='bbox 1978 1857 2069 1894; x_wconf 89' lang='eng' dir='ltr'>then</span>
</span>
<span class='ocr_line' id='line_1_23' title="bbox 457 1910 2069 1958; baseline 0.004 -12"><span class='ocrx_word' id='word_1_293' title='bbox 457 1910 599 1955; x_wconf 87' lang='eng' dir='ltr'>dipped</span> <span class='ocrx_word' id='word_1_294' title='bbox 621 1911 808 1956; x_wconf 90' lang='eng' dir='ltr'>suddenly</span> <span class='ocrx_word' id='word_1_295' title='bbox 829 1912 950 1956; x_wconf 91' lang='eng' dir='ltr'>down,</span> <span class='ocrx_word' id='word_1_296' title='bbox 975 1925 1016 1948; x_wconf 92' lang='eng' dir='ltr'>so</span> <span class='ocrx_word' id='word_1_297' title='bbox 1037 1913 1223 1958; x_wconf 91' lang='eng' dir='ltr'>suddenly</span> <span class='ocrx_word' id='word_1_298' title='bbox 1243 1914 1329 1950; x_wconf 91' lang='eng' dir='ltr'>that</span> <span class='ocrx_word' id='word_1_299' title='bbox 1351 1913 1456 1951; x_wconf 89' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_300' title='bbox 1477 1915 1554 1951; x_wconf 91' lang='eng' dir='ltr'>had</span> <span class='ocrx_word' id='word_1_301' title='bbox 1575 1920 1642 1951; x_wconf 94' lang='eng' dir='ltr'>not</span> <span class='ocrx_word' id='word_1_302' title='bbox 1665 1928 1689 1952; x_wconf 93' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_303' title='bbox 1709 1921 1877 1952; x_wconf 91' lang='eng' dir='ltr'>moment</span> <span class='ocrx_word' id='word_1_304' title='bbox 1898 1921 1940 1953; x_wconf 89' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_305' title='bbox 1960 1917 2069 1953; x_wconf 91' lang='eng' dir='ltr'>think</span>
</span>
<span class='ocr_line' id='line_1_24' title="bbox 457 1969 2066 2022; baseline 0.004 -16"><span class='ocrx_word' id='word_1_306' title='bbox 457 1969 575 2006; x_wconf 90' lang='eng' dir='ltr'>about</span> <span class='ocrx_word' id='word_1_307' title='bbox 593 1972 774 2017; x_wconf 88' lang='eng' dir='ltr'>stopping</span> <span class='ocrx_word' id='word_1_308' title='bbox 790 1970 929 2008; x_wconf 88' lang='eng' dir='ltr'>herself</span> <span class='ocrx_word' id='word_1_309' title='bbox 941 1971 1069 2009; x_wconf 89' lang='eng' dir='ltr'>before</span> <span class='ocrx_word' id='word_1_310' title='bbox 1085 1972 1150 2009; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_311' title='bbox 1166 1972 1284 2010; x_wconf 90' lang='eng' dir='ltr'>found</span> <span class='ocrx_word' id='word_1_312' title='bbox 1300 1973 1438 2010; x_wconf 92' lang='eng' dir='ltr'>herself</span> <span class='ocrx_word' id='word_1_313' title='bbox 1450 1973 1581 2021; x_wconf 89' lang='eng' dir='ltr'>falling</span> <span class='ocrx_word' id='word_1_314' title='bbox 1596 1975 1707 2012; x_wconf 92' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_315' title='bbox 1724 1988 1747 2012; x_wconf 95' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_316' title='bbox 1762 1988 1851 2022; x_wconf 90' lang='eng' dir='ltr'>very</span> <span class='ocrx_word' id='word_1_317' title='bbox 1867 1976 1960 2022; x_wconf 89' lang='eng' dir='ltr'>deep</span> <span class='ocrx_word' id='word_1_318' title='bbox 1976 1977 2066 2013; x_wconf 86' lang='eng' dir='ltr'>well.</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_7' title="bbox 453 2030 2069 2618">
<span class='ocr_line' id='line_1_25' title="bbox 530 2030 2069 2083; baseline 0.005 -18"><span class='ocrx_word' id='word_1_319' title='bbox 530 2030 660 2066; x_wconf 89' lang='eng' dir='ltr'>Either</span> <span class='ocrx_word' id='word_1_320' title='bbox 679 2030 745 2066; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_321' title='bbox 765 2031 846 2067; x_wconf 92' lang='eng' dir='ltr'>well</span> <span class='ocrx_word' id='word_1_322' title='bbox 865 2043 941 2067; x_wconf 90' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_323' title='bbox 960 2044 1049 2077; x_wconf 89' lang='eng' dir='ltr'>very</span> <span class='ocrx_word' id='word_1_324' title='bbox 1067 2032 1173 2078; x_wconf 90' lang='eng' dir='ltr'>deep,</span> <span class='ocrx_word' id='word_1_325' title='bbox 1195 2045 1236 2069; x_wconf 90' lang='eng' dir='ltr'>or</span> <span class='ocrx_word' id='word_1_326' title='bbox 1255 2033 1320 2069; x_wconf 90' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_327' title='bbox 1339 2033 1401 2070; x_wconf 89' lang='eng' dir='ltr'>fell</span> <span class='ocrx_word' id='word_1_328' title='bbox 1419 2046 1509 2080; x_wconf 91' lang='eng' dir='ltr'>very</span> <span class='ocrx_word' id='word_1_329' title='bbox 1528 2034 1664 2081; x_wconf 90' lang='eng' dir='ltr'>slowly,</span> <span class='ocrx_word' id='word_1_330' title='bbox 1686 2034 1743 2071; x_wconf 90' lang='eng' dir='ltr'>for</span> <span class='ocrx_word' id='word_1_331' title='bbox 1762 2035 1827 2072; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_332' title='bbox 1847 2036 1923 2072; x_wconf 93' lang='eng' dir='ltr'>had</span> <span class='ocrx_word' id='word_1_333' title='bbox 1942 2036 2069 2083; x_wconf 91' lang='eng' dir='ltr'>plenty</span>
</span>
<span class='ocr_line' id='line_1_26' title="bbox 456 2089 2069 2142; baseline 0.005 -18"><span class='ocrx_word' id='word_1_334' title='bbox 456 2089 496 2124; x_wconf 89' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_335' title='bbox 512 2091 605 2125; x_wconf 91' lang='eng' dir='ltr'>time</span> <span class='ocrx_word' id='word_1_336' title='bbox 625 2102 666 2125; x_wconf 90' lang='eng' dir='ltr'>as</span> <span class='ocrx_word' id='word_1_337' title='bbox 687 2090 752 2126; x_wconf 93' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_338' title='bbox 772 2095 869 2126; x_wconf 91' lang='eng' dir='ltr'>went</span> <span class='ocrx_word' id='word_1_339' title='bbox 891 2091 1001 2127; x_wconf 90' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_340' title='bbox 1020 2096 1062 2127; x_wconf 94' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_341' title='bbox 1081 2092 1168 2128; x_wconf 92' lang='eng' dir='ltr'>look</span> <span class='ocrx_word' id='word_1_342' title='bbox 1188 2093 1306 2129; x_wconf 89' lang='eng' dir='ltr'>about</span> <span class='ocrx_word' id='word_1_343' title='bbox 1327 2093 1392 2129; x_wconf 92' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_344' title='bbox 1413 2094 1489 2130; x_wconf 88' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_345' title='bbox 1508 2099 1550 2130; x_wconf 92' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_346' title='bbox 1569 2095 1722 2130; x_wconf 90' lang='eng' dir='ltr'>wonder</span> <span class='ocrx_word' id='word_1_347' title='bbox 1741 2096 1844 2131; x_wconf 90' lang='eng' dir='ltr'>what</span> <span class='ocrx_word' id='word_1_348' title='bbox 1864 2108 1939 2132; x_wconf 88' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_349' title='bbox 1959 2098 2069 2142; x_wconf 89' lang='eng' dir='ltr'>going</span>
</span>
<span class='ocr_line' id='line_1_27' title="bbox 455 2150 2068 2195; baseline 0.006 -11"><span class='ocrx_word' id='word_1_350' title='bbox 455 2154 496 2185; x_wconf 87' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_351' title='bbox 517 2150 671 2194; x_wconf 90' lang='eng' dir='ltr'>happen</span> <span class='ocrx_word' id='word_1_352' title='bbox 692 2155 794 2186; x_wconf 83' lang='eng' dir='ltr'>next.</span> <span class='ocrx_word' id='word_1_353' title='bbox 830 2152 940 2195; x_wconf 88' lang='eng' dir='ltr'>First,</span> <span class='ocrx_word' id='word_1_354' title='bbox 964 2152 1029 2187; x_wconf 93' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_355' title='bbox 1049 2153 1148 2188; x_wconf 88' lang='eng' dir='ltr'>tried</span> <span class='ocrx_word' id='word_1_356' title='bbox 1167 2157 1209 2188; x_wconf 91' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_357' title='bbox 1229 2153 1316 2189; x_wconf 92' lang='eng' dir='ltr'>look</span> <span class='ocrx_word' id='word_1_358' title='bbox 1337 2154 1447 2189; x_wconf 89' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_359' title='bbox 1468 2155 1544 2190; x_wconf 90' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_360' title='bbox 1565 2155 1675 2190; x_wconf 91' lang='eng' dir='ltr'>make</span> <span class='ocrx_word' id='word_1_361' title='bbox 1696 2160 1763 2191; x_wconf 92' lang='eng' dir='ltr'>out</span> <span class='ocrx_word' id='word_1_362' title='bbox 1785 2156 1887 2192; x_wconf 92' lang='eng' dir='ltr'>what</span> <span class='ocrx_word' id='word_1_363' title='bbox 1909 2157 1974 2192; x_wconf 92' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_364' title='bbox 1994 2169 2068 2193; x_wconf 89' lang='eng' dir='ltr'>was</span>
</span>
<span class='ocr_line' id='line_1_28' title="bbox 455 2210 2068 2259; baseline 0.005 -14"><span class='ocrx_word' id='word_1_365' title='bbox 455 2211 605 2255; x_wconf 90' lang='eng' dir='ltr'>coming</span> <span class='ocrx_word' id='word_1_366' title='bbox 623 2214 676 2254; x_wconf 94' lang='eng' dir='ltr'>to,</span> <span class='ocrx_word' id='word_1_367' title='bbox 696 2210 767 2246; x_wconf 91' lang='eng' dir='ltr'>but</span> <span class='ocrx_word' id='word_1_368' title='bbox 787 2212 816 2247; x_wconf 89' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_369' title='bbox 835 2223 911 2247; x_wconf 92' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_370' title='bbox 929 2215 996 2247; x_wconf 95' lang='eng' dir='ltr'>too</span> <span class='ocrx_word' id='word_1_371' title='bbox 1014 2211 1108 2248; x_wconf 92' lang='eng' dir='ltr'>dark</span> <span class='ocrx_word' id='word_1_372' title='bbox 1125 2216 1167 2248; x_wconf 92' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_373' title='bbox 1185 2225 1245 2249; x_wconf 91' lang='eng' dir='ltr'>see</span> <span class='ocrx_word' id='word_1_374' title='bbox 1263 2213 1458 2259; x_wconf 90' lang='eng' dir='ltr'>anything;</span> <span class='ocrx_word' id='word_1_375' title='bbox 1478 2214 1572 2250; x_wconf 89' lang='eng' dir='ltr'>then</span> <span class='ocrx_word' id='word_1_376' title='bbox 1591 2214 1657 2251; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_377' title='bbox 1675 2214 1811 2251; x_wconf 91' lang='eng' dir='ltr'>looked</span> <span class='ocrx_word' id='word_1_378' title='bbox 1829 2220 1869 2251; x_wconf 92' lang='eng' dir='ltr'>at</span> <span class='ocrx_word' id='word_1_379' title='bbox 1888 2216 1953 2252; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_380' title='bbox 1971 2216 2068 2253; x_wconf 90' lang='eng' dir='ltr'>sides</span>
</span>
<span class='ocr_line' id='line_1_29' title="bbox 454 2268 2067 2320; baseline 0.005 -16"><span class='ocrx_word' id='word_1_381' title='bbox 454 2268 495 2305; x_wconf 90' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_382' title='bbox 517 2269 583 2305; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_383' title='bbox 609 2269 701 2314; x_wconf 88' lang='eng' dir='ltr'>well,</span> <span class='ocrx_word' id='word_1_384' title='bbox 733 2270 809 2307; x_wconf 93' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_385' title='bbox 835 2271 987 2307; x_wconf 90' lang='eng' dir='ltr'>noticed</span> <span class='ocrx_word' id='word_1_386' title='bbox 1012 2271 1098 2308; x_wconf 87' lang='eng' dir='ltr'>that</span> <span class='ocrx_word' id='word_1_387' title='bbox 1124 2271 1216 2318; x_wconf 88' lang='eng' dir='ltr'>they</span> <span class='ocrx_word' id='word_1_388' title='bbox 1241 2285 1335 2309; x_wconf 88' lang='eng' dir='ltr'>were</span> <span class='ocrx_word' id='word_1_389' title='bbox 1360 2272 1462 2310; x_wconf 91' lang='eng' dir='ltr'>filled</span> <span class='ocrx_word' id='word_1_390' title='bbox 1487 2274 1581 2310; x_wconf 92' lang='eng' dir='ltr'>with</span> <span class='ocrx_word' id='word_1_391' title='bbox 1607 2274 1824 2320; x_wconf 88' lang='eng' dir='ltr'>cupboards</span> <span class='ocrx_word' id='word_1_392' title='bbox 1850 2275 1926 2312; x_wconf 91' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_393' title='bbox 1951 2276 2067 2312; x_wconf 93' lang='eng' dir='ltr'>book-</span>
</span>
<span class='ocr_line' id='line_1_30' title="bbox 454 2329 2067 2381; baseline 0.005 -16"><span class='ocrx_word' id='word_1_394' title='bbox 454 2329 610 2374; x_wconf 88' lang='eng' dir='ltr'>shelves;</span> <span class='ocrx_word' id='word_1_395' title='bbox 630 2329 717 2366; x_wconf 90' lang='eng' dir='ltr'>here</span> <span class='ocrx_word' id='word_1_396' title='bbox 734 2330 810 2367; x_wconf 93' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_397' title='bbox 826 2330 933 2367; x_wconf 92' lang='eng' dir='ltr'>there</span> <span class='ocrx_word' id='word_1_398' title='bbox 949 2331 1014 2368; x_wconf 92' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_399' title='bbox 1031 2344 1106 2368; x_wconf 91' lang='eng' dir='ltr'>saw</span> <span class='ocrx_word' id='word_1_400' title='bbox 1121 2344 1229 2378; x_wconf 91' lang='eng' dir='ltr'>maps</span> <span class='ocrx_word' id='word_1_401' title='bbox 1246 2332 1321 2369; x_wconf 89' lang='eng' dir='ltr'>and</span> <span class='ocrx_word' id='word_1_402' title='bbox 1337 2334 1503 2378; x_wconf 89' lang='eng' dir='ltr'>pictures</span> <span class='ocrx_word' id='word_1_403' title='bbox 1519 2333 1622 2380; x_wconf 91' lang='eng' dir='ltr'>hung</span> <span class='ocrx_word' id='word_1_404' title='bbox 1638 2347 1744 2380; x_wconf 93' lang='eng' dir='ltr'>upon</span> <span class='ocrx_word' id='word_1_405' title='bbox 1760 2347 1861 2381; x_wconf 88' lang='eng' dir='ltr'>pegs.</span> <span class='ocrx_word' id='word_1_406' title='bbox 1888 2335 1960 2373; x_wconf 92' lang='eng' dir='ltr'>She</span> <span class='ocrx_word' id='word_1_407' title='bbox 1976 2336 2067 2373; x_wconf 91' lang='eng' dir='ltr'>took</span>
</span>
<span class='ocr_line' id='line_1_31' title="bbox 454 2389 2066 2439; baseline 0.006 -14"><span class='ocrx_word' id='word_1_408' title='bbox 454 2389 564 2426; x_wconf 92' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_409' title='bbox 583 2402 606 2426; x_wconf 89' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_410' title='bbox 620 2391 679 2436; x_wconf 91' lang='eng' dir='ltr'>jar</span> <span class='ocrx_word' id='word_1_411' title='bbox 698 2389 796 2427; x_wconf 89' lang='eng' dir='ltr'>from</span> <span class='ocrx_word' id='word_1_412' title='bbox 814 2403 885 2428; x_wconf 90' lang='eng' dir='ltr'>one</span> <span class='ocrx_word' id='word_1_413' title='bbox 904 2390 945 2428; x_wconf 89' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_414' title='bbox 959 2391 1025 2428; x_wconf 91' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_415' title='bbox 1043 2391 1186 2429; x_wconf 90' lang='eng' dir='ltr'>shelves</span> <span class='ocrx_word' id='word_1_416' title='bbox 1205 2405 1246 2430; x_wconf 91' lang='eng' dir='ltr'>as</span> <span class='ocrx_word' id='word_1_417' title='bbox 1264 2392 1329 2430; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_418' title='bbox 1347 2393 1495 2439; x_wconf 89' lang='eng' dir='ltr'>passed;</span> <span class='ocrx_word' id='word_1_419' title='bbox 1516 2395 1545 2431; x_wconf 90' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_420' title='bbox 1564 2407 1641 2431; x_wconf 90' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_421' title='bbox 1659 2394 1822 2432; x_wconf 90' lang='eng' dir='ltr'>labelled</span> <span class='ocrx_word' id='word_1_422' title='bbox 1842 2394 2066 2434; x_wconf 86' lang='eng' dir='ltr'>‘ORANGE</span>
</span>
<span class='ocr_line' id='line_1_32' title="bbox 454 2449 2065 2501; baseline 0.005 -16"><span class='ocrx_word' id='word_1_423' title='bbox 454 2449 813 2496; x_wconf 90' lang='eng' dir='ltr'>MARMALADE’,</span> <span class='ocrx_word' id='word_1_424' title='bbox 832 2451 903 2487; x_wconf 90' lang='eng' dir='ltr'>but</span> <span class='ocrx_word' id='word_1_425' title='bbox 921 2455 962 2488; x_wconf 90' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_426' title='bbox 979 2451 1045 2488; x_wconf 89' lang='eng' dir='ltr'>her</span> <span class='ocrx_word' id='word_1_427' title='bbox 1061 2456 1165 2498; x_wconf 89' lang='eng' dir='ltr'>great</span> <span class='ocrx_word' id='word_1_428' title='bbox 1184 2452 1508 2499; x_wconf 88' lang='eng' dir='ltr'>disappointment</span> <span class='ocrx_word' id='word_1_429' title='bbox 1526 2455 1556 2491; x_wconf 92' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_430' title='bbox 1574 2466 1650 2491; x_wconf 90' lang='eng' dir='ltr'>was</span> <span class='ocrx_word' id='word_1_431' title='bbox 1668 2459 1809 2501; x_wconf 90' lang='eng' dir='ltr'>empty:</span> <span class='ocrx_word' id='word_1_432' title='bbox 1836 2455 1900 2492; x_wconf 90' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_433' title='bbox 1918 2456 1983 2493; x_wconf 94' lang='eng' dir='ltr'>did</span> <span class='ocrx_word' id='word_1_434' title='bbox 1999 2460 2065 2493; x_wconf 91' lang='eng' dir='ltr'>not</span>
</span>
<span class='ocr_line' id='line_1_33' title="bbox 453 2510 2066 2562; baseline 0.005 -17"><span class='ocrx_word' id='word_1_435' title='bbox 453 2510 524 2546; x_wconf 89' lang='eng' dir='ltr'>like</span> <span class='ocrx_word' id='word_1_436' title='bbox 544 2515 586 2546; x_wconf 90' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_437' title='bbox 607 2511 703 2556; x_wconf 95' lang='eng' dir='ltr'>drop</span> <span class='ocrx_word' id='word_1_438' title='bbox 723 2511 790 2547; x_wconf 88' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_439' title='bbox 808 2513 867 2557; x_wconf 84' lang='eng' dir='ltr'>jar</span> <span class='ocrx_word' id='word_1_440' title='bbox 889 2511 945 2548; x_wconf 89' lang='eng' dir='ltr'>for</span> <span class='ocrx_word' id='word_1_441' title='bbox 966 2512 1043 2548; x_wconf 87' lang='eng' dir='ltr'>fear</span> <span class='ocrx_word' id='word_1_442' title='bbox 1064 2512 1104 2549; x_wconf 90' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_443' title='bbox 1121 2513 1250 2559; x_wconf 90' lang='eng' dir='ltr'>killing</span> <span class='ocrx_word' id='word_1_444' title='bbox 1270 2514 1487 2560; x_wconf 90' lang='eng' dir='ltr'>somebody,</span> <span class='ocrx_word' id='word_1_445' title='bbox 1511 2527 1553 2551; x_wconf 92' lang='eng' dir='ltr'>so</span> <span class='ocrx_word' id='word_1_446' title='bbox 1574 2515 1763 2562; x_wconf 92' lang='eng' dir='ltr'>managed</span> <span class='ocrx_word' id='word_1_447' title='bbox 1782 2520 1824 2552; x_wconf 92' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_448' title='bbox 1845 2520 1914 2562; x_wconf 89' lang='eng' dir='ltr'>put</span> <span class='ocrx_word' id='word_1_449' title='bbox 1936 2518 1965 2553; x_wconf 94' lang='eng' dir='ltr'>it</span> <span class='ocrx_word' id='word_1_450' title='bbox 1987 2518 2066 2553; x_wconf 91' lang='eng' dir='ltr'>into</span>
</span>
<span class='ocr_line' id='line_1_34' title="bbox 453 2571 1286 2618; baseline 0.005 -13"><span class='ocrx_word' id='word_1_451' title='bbox 453 2583 523 2606; x_wconf 91' lang='eng' dir='ltr'>one</span> <span class='ocrx_word' id='word_1_452' title='bbox 542 2571 582 2606; x_wconf 88' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_453' title='bbox 597 2571 663 2606; x_wconf 93' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_454' title='bbox 682 2572 899 2616; x_wconf 91' lang='eng' dir='ltr'>cupboards</span> <span class='ocrx_word' id='word_1_455' title='bbox 918 2585 959 2608; x_wconf 91' lang='eng' dir='ltr'>as</span> <span class='ocrx_word' id='word_1_456' title='bbox 978 2573 1043 2608; x_wconf 91' lang='eng' dir='ltr'>she</span> <span class='ocrx_word' id='word_1_457' title='bbox 1061 2573 1123 2609; x_wconf 89' lang='eng' dir='ltr'>fell</span> <span class='ocrx_word' id='word_1_458' title='bbox 1140 2578 1226 2618; x_wconf 87' lang='eng' dir='ltr'>past</span> <span class='ocrx_word' id='word_1_459' title='bbox 1246 2575 1286 2609; x_wconf 91' lang='eng' dir='ltr'>it.</span>
</span>
</p>
<p class='ocr_par' dir='ltr' id='par_1_8' title="bbox 451 2630 2065 2800">
<span class='ocr_line' id='line_1_35' title="bbox 528 2630 2065 2680; baseline 0.005 -14"><span class='ocrx_word' id='word_1_460' title='bbox 528 2630 657 2667; x_wconf 85' lang='eng' dir='ltr'>‘Well!’</span> <span class='ocrx_word' id='word_1_461' title='bbox 695 2631 860 2677; x_wconf 90' lang='eng' dir='ltr'>thought</span> <span class='ocrx_word' id='word_1_462' title='bbox 884 2631 988 2668; x_wconf 92' lang='eng' dir='ltr'>Alice</span> <span class='ocrx_word' id='word_1_463' title='bbox 1010 2636 1052 2668; x_wconf 92' lang='eng' dir='ltr'>to</span> <span class='ocrx_word' id='word_1_464' title='bbox 1075 2632 1219 2678; x_wconf 90' lang='eng' dir='ltr'>herself,</span> <span class='ocrx_word' id='word_1_465' title='bbox 1247 2633 1355 2670; x_wconf 90' lang='eng' dir='ltr'>‘after</span> <span class='ocrx_word' id='word_1_466' title='bbox 1377 2634 1469 2670; x_wconf 92' lang='eng' dir='ltr'>such</span> <span class='ocrx_word' id='word_1_467' title='bbox 1492 2647 1515 2671; x_wconf 93' lang='eng' dir='ltr'>a</span> <span class='ocrx_word' id='word_1_468' title='bbox 1536 2634 1601 2671; x_wconf 88' lang='eng' dir='ltr'>fall</span> <span class='ocrx_word' id='word_1_469' title='bbox 1624 2647 1665 2671; x_wconf 93' lang='eng' dir='ltr'>as</span> <span class='ocrx_word' id='word_1_470' title='bbox 1687 2635 1776 2680; x_wconf 92' lang='eng' dir='ltr'>this,</span> <span class='ocrx_word' id='word_1_471' title='bbox 1803 2636 1817 2672; x_wconf 95' lang='eng' dir='ltr'>I</span> <span class='ocrx_word' id='word_1_472' title='bbox 1840 2636 1935 2672; x_wconf 92' lang='eng' dir='ltr'>shall</span> <span class='ocrx_word' id='word_1_473' title='bbox 1956 2636 2065 2673; x_wconf 90' lang='eng' dir='ltr'>think</span>
</span>
<span class='ocr_line' id='line_1_36' title="bbox 453 2690 2062 2740; baseline 0.004 -15"><span class='ocrx_word' id='word_1_474' title='bbox 453 2690 613 2736; x_wconf 88' lang='eng' dir='ltr'>nothing</span> <span class='ocrx_word' id='word_1_475' title='bbox 635 2690 675 2726; x_wconf 90' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_476' title='bbox 693 2691 883 2737; x_wconf 92' lang='eng' dir='ltr'>tumbling</span> <span class='ocrx_word' id='word_1_477' title='bbox 905 2692 1015 2728; x_wconf 90' lang='eng' dir='ltr'>down</span> <span class='ocrx_word' id='word_1_478' title='bbox 1036 2692 1158 2728; x_wconf 88' lang='eng' dir='ltr'>stairs!</span> <span class='ocrx_word' id='word_1_479' title='bbox 1195 2693 1287 2729; x_wconf 89' lang='eng' dir='ltr'>How</span> <span class='ocrx_word' id='word_1_480' title='bbox 1307 2693 1419 2730; x_wconf 91' lang='eng' dir='ltr'>brave</span> <span class='ocrx_word' id='word_1_481' title='bbox 1440 2694 1574 2740; x_wconf 91' lang='eng' dir='ltr'>they’ll</span> <span class='ocrx_word' id='word_1_482' title='bbox 1595 2695 1645 2731; x_wconf 92' lang='eng' dir='ltr'>all</span> <span class='ocrx_word' id='word_1_483' title='bbox 1666 2695 1778 2731; x_wconf 92' lang='eng' dir='ltr'>think</span> <span class='ocrx_word' id='word_1_484' title='bbox 1799 2708 1859 2732; x_wconf 91' lang='eng' dir='ltr'>me</span> <span class='ocrx_word' id='word_1_485' title='bbox 1880 2700 1920 2732; x_wconf 94' lang='eng' dir='ltr'>at</span> <span class='ocrx_word' id='word_1_486' title='bbox 1942 2696 2062 2732; x_wconf 85' lang='eng' dir='ltr'>home!</span>
</span>
<span class='ocr_line' id='line_1_37' title="bbox 451 2750 2063 2800; baseline 0.004 -15"><span class='ocrx_word' id='word_1_487' title='bbox 451 2750 558 2795; x_wconf 89' lang='eng' dir='ltr'>Why,</span> <span class='ocrx_word' id='word_1_488' title='bbox 578 2750 592 2785; x_wconf 91' lang='eng' dir='ltr'>I</span> <span class='ocrx_word' id='word_1_489' title='bbox 609 2750 793 2787; x_wconf 90' lang='eng' dir='ltr'>wouldn’t</span> <span class='ocrx_word' id='word_1_490' title='bbox 811 2764 877 2796; x_wconf 90' lang='eng' dir='ltr'>say</span> <span class='ocrx_word' id='word_1_491' title='bbox 894 2752 1078 2798; x_wconf 90' lang='eng' dir='ltr'>anything</span> <span class='ocrx_word' id='word_1_492' title='bbox 1094 2752 1213 2789; x_wconf 91' lang='eng' dir='ltr'>about</span> <span class='ocrx_word' id='word_1_493' title='bbox 1230 2754 1271 2797; x_wconf 90' lang='eng' dir='ltr'>it,</span> <span class='ocrx_word' id='word_1_494' title='bbox 1291 2766 1383 2789; x_wconf 92' lang='eng' dir='ltr'>even</span> <span class='ocrx_word' id='word_1_495' title='bbox 1400 2753 1429 2789; x_wconf 89' lang='eng' dir='ltr'>if</span> <span class='ocrx_word' id='word_1_496' title='bbox 1443 2754 1457 2789; x_wconf 88' lang='eng' dir='ltr'>I</span> <span class='ocrx_word' id='word_1_497' title='bbox 1474 2754 1536 2790; x_wconf 90' lang='eng' dir='ltr'>fell</span> <span class='ocrx_word' id='word_1_498' title='bbox 1553 2754 1607 2790; x_wconf 86' lang='eng' dir='ltr'>off</span> <span class='ocrx_word' id='word_1_499' title='bbox 1619 2755 1686 2791; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_500' title='bbox 1702 2759 1771 2800; x_wconf 92' lang='eng' dir='ltr'>top</span> <span class='ocrx_word' id='word_1_501' title='bbox 1788 2755 1828 2791; x_wconf 89' lang='eng' dir='ltr'>of</span> <span class='ocrx_word' id='word_1_502' title='bbox 1841 2756 1906 2792; x_wconf 92' lang='eng' dir='ltr'>the</span> <span class='ocrx_word' id='word_1_503' title='bbox 1923 2756 2063 2792; x_wconf 92' lang='eng' dir='ltr'>house!’</span>
</span>
</p>
</div>
</div>
</body>
</html>
@@ -0,0 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
<PcGts xmlns="http://schema.primaresearch.org/PAGE/gts/pagecontent/2019-07-15">
<Metadata>
<Creator>Galaxy datatype test fixture</Creator>
<Created>2026-10-03T00:00:00Z</Created>
<LastChange>2026-10-03T00:00:00Z</LastChange>
</Metadata>
<Page imageFilename="sample.png" imageWidth="800" imageHeight="600">
<ReadingOrder>
<OrderedGroup id="reading_order">
<RegionRefIndexed index="0" regionRef="region_1"/>
</OrderedGroup>
</ReadingOrder>
<TextRegion id="region_1" type="paragraph">
<Coords points="50,50 750,50 750,120 50,120"/>
<TextLine id="line_1">
<Coords points="50,50 400,50 400,100 50,100"/>
<Baseline points="50,90 400,90"/>
<Word id="word_1">
<Coords points="50,50 180,50 180,100 50,100"/>
<TextEquiv conf="0.99"><Unicode>Hello</Unicode></TextEquiv>
</Word>
<Word id="word_2">
<Coords points="200,50 400,50 400,100 200,100"/>
<TextEquiv conf="0.98"><Unicode>Galaxy</Unicode></TextEquiv>
</Word>
<TextEquiv><Unicode>Hello Galaxy</Unicode></TextEquiv>
</TextLine>
<TextEquiv><Unicode>Hello Galaxy</Unicode></TextEquiv>
</TextRegion>
</Page>
</PcGts>
+27
View File
@@ -8,6 +8,7 @@ import re
import shlex
import subprocess
import tempfile
from html.parser import HTMLParser
from typing import (
IO,
TYPE_CHECKING,
@@ -92,6 +93,32 @@ class Html(Text):
return False
class _HocrParser(HTMLParser):
"""Recognize an hOCR page class without matching comments or script text."""
def __init__(self):
super().__init__()
self.has_page = False
def handle_starttag(self, tag, attrs):
for name, value in attrs:
if name == "class" and value and "ocr_page" in value.split():
self.has_page = True
class Hocr(Html):
"""HTML or XHTML containing hOCR recognition data."""
file_ext = "hocr"
def sniff_prefix(self, file_prefix: FilePrefix) -> bool:
if not file_prefix.search_str("ocr_page"):
return False
parser = _HocrParser()
parser.feed(file_prefix.string_io().read())
return parser.has_page
@build_sniff_from_prefix
class Json(Text):
edam_format = "format_3464"
+60
View File
@@ -4,6 +4,7 @@ XML format classes
import logging
import re
from xml.parsers import expat
from galaxy import util
from galaxy.datatypes.dataproviders.dataset import DatasetDataProvider
@@ -88,6 +89,65 @@ class GenericXml(data.Text):
return XMLDataProvider(dataset_source, **settings)
class _XmlRootFound(Exception):
"""Stop parsing as soon as the root start tag has been read."""
def _sniff_xml_root(file_prefix: FilePrefix, root: str, namespace_pattern: str) -> bool:
# Parse only the root, so truncated prefixes and large OCR documents work.
# Expat does not fetch external entities without an external entity handler.
parser = expat.ParserCreate(namespace_separator="}")
matches = False
def start_element(name, attrs):
nonlocal matches
namespace, _, local_name = name.rpartition("}")
matches = local_name == root and re.fullmatch(namespace_pattern, namespace) is not None
raise _XmlRootFound
parser.StartElementHandler = start_element
try:
parser.Parse(file_prefix.contents_header_bytes, False)
except _XmlRootFound:
return matches
except expat.ExpatError:
pass
return False
class PageXml(GenericXml):
"""PAGE XML layout and text recognition data."""
file_ext = "page.xml"
def sniff_prefix(self, file_prefix: FilePrefix) -> bool:
return _sniff_xml_root(
file_prefix, "PcGts", r"http://schema\.primaresearch\.org/PAGE/gts/pagecontent/\d{4}-\d{2}-\d{2}"
)
class Alto(GenericXml):
"""ALTO layout and text recognition data, including the original v1 namespace."""
file_ext = "alto"
def sniff_prefix(self, file_prefix: FilePrefix) -> bool:
return _sniff_xml_root(
file_prefix, "alto", r"(?:http://www\.loc\.gov/standards/alto/ns-v\d+#|http://schema\.ccs-gmbh\.com/ALTO)"
)
class AbbyyXml(GenericXml):
"""ABBYY FineReader XML recognition data."""
file_ext = "abbyy.xml"
def sniff_prefix(self, file_prefix: FilePrefix) -> bool:
return _sniff_xml_root(
file_prefix, "document", r"http://www\.abbyy\.com/FineReader_xml/FineReader\d+-schema-v\d+\.xml"
)
@disable_parent_class_sniffing
class MEMEXml(GenericXml):
"""MEME XML Output data"""
+7 -5
View File
@@ -62,13 +62,15 @@ def create_user(app: ToolShedApp, email: str, username: str, password: str) -> U
return user
def ensure_valid_new_user(trans: ProvidesUserContext, email: str, username: str, password: str) -> None:
"""Raise RequestParameterInvalidException unless a new account may use these values."""
if message := _validate(trans, email=email, password=password, confirm=password, username=username):
raise RequestParameterInvalidException(message)
def api_create_user(trans: ProvidesUserContext, request: CreateUserRequest) -> ApiUser:
app = trans.app
message = _validate(
trans, email=request.email, password=request.password, confirm=request.password, username=request.username
)
if message:
raise RequestParameterInvalidException(message)
ensure_valid_new_user(trans, email=request.email, username=request.username, password=request.password)
user = create_user(app, request.email, request.username, request.password)
return get_api_user(app, user)
@@ -217,5 +217,30 @@ class TestShedUsersApi(ShedApiTestCase):
users = self.admin_api_interactor.get("users").json()
return next(user["id"] for user in users if user["username"] == username)
def test_register(self):
email = "testregister@bx.psu.edu"
password = "mycoolpassword123"
response = self._register(email=email, username=email_to_username(email), password=password)
api_asserts.assert_status_code_is_ok(response)
self._verify_username_password(email, password)
def test_register_rejects_invalid_username(self):
response = self._register(email="testregisterbadname@bx.psu.edu", username="Not Valid")
api_asserts.assert_status_code_is(response, 400)
def test_register_rejects_taken_username(self):
email = "testregistertaken@bx.psu.edu"
ensure_user_with_email(self.admin_api_interactor, email, "mycoolpassword123")
response = self._register(email="testregistertakenother@bx.psu.edu", username=email_to_username(email))
api_asserts.assert_status_code_is(response, 400)
def test_register_rejects_invalid_email(self):
response = self._register(email="not an email", username="testregisterbademail")
api_asserts.assert_status_code_is(response, 400)
def _register(self, email: str, username: str, password: str = "mycoolpassword123"):
url = urljoin(self.url, "api_internal/register")
return post(url, json={"email": email, "username": username, "password": password, "bear_field": ""})
def _verify_username_password(self, email: str, password: str) -> str:
return self.api_interactor.create_api_key(email, password)
+4 -2
View File
@@ -30,6 +30,7 @@ from galaxy.webapps.base.webapp import create_new_session
from tool_shed.context import SessionRequestContext
from tool_shed.managers.users import (
api_create_user,
ensure_valid_new_user,
get_api_user,
index,
send_password_reset_email,
@@ -264,8 +265,9 @@ class FastAPIUsers:
register_request: UiRegisterRequest = Body(...),
) -> UiRegisterResponse:
username = register_request.username
if username == "repos":
raise RequestParameterInvalidException("Cannot create a user with the username 'repos'")
ensure_valid_new_user(
trans, email=register_request.email, username=username, password=register_request.password
)
self.user_manager.create(email=register_request.email, username=username, password=register_request.password)
if self.app.config.user_activation_on:
is_activation_sent = self.user_manager.send_activation_email(trans, register_request.email, username)
+1 -1
View File
@@ -110,7 +110,7 @@ class User(Base, Dictifiable):
create_time: Mapped[datetime | None] = mapped_column(DateTime, default=now)
update_time: Mapped[datetime | None] = mapped_column(DateTime, default=now, onupdate=now)
email: Mapped[str] = mapped_column(TrimmedString(255), nullable=False)
username: Mapped[str | None] = mapped_column(String(255), index=True)
username: Mapped[str | None] = mapped_column(String(255), index=True, unique=True)
password: Mapped[str] = mapped_column(TrimmedString(40), nullable=False)
external: Mapped[bool | None] = mapped_column(Boolean, default=False)
new_repo_alert: Mapped[bool | None] = mapped_column(Boolean, default=False)
@@ -0,0 +1,38 @@
"""Username column unique constraint
Revision ID: 3b0a43f181af
Revises: 1b5bf427db25
Create Date: 2026-10-07 12:00:00.000000
"""
from galaxy.model.database_object_names import build_index_name
from galaxy.model.migrations.util import (
create_index,
drop_index,
index_exists,
transaction,
)
# revision identifiers, used by Alembic.
revision = "3b0a43f181af"
down_revision = "1b5bf427db25"
branch_labels = None
depends_on = None
table_name = "galaxy_user"
column_name = "username"
index_name = build_index_name(table_name, [column_name])
def upgrade() -> None:
with transaction():
if index_exists(index_name, table_name, True):
drop_index(index_name, table_name)
create_index(index_name, table_name, [column_name], unique=True)
def downgrade() -> None:
with transaction():
drop_index(index_name, table_name)
create_index(index_name, table_name, [column_name])
+177
View File
@@ -0,0 +1,177 @@
import pytest
from galaxy.datatypes.registry import example_datatype_registry_for_sample
from galaxy.datatypes.sniff import (
FilePrefix,
get_test_fname,
guess_ext,
)
from galaxy.datatypes.text import (
Hocr,
Html,
)
from galaxy.datatypes.xml import (
AbbyyXml,
Alto,
GenericXml,
PageXml,
)
XML_FORMATS = [
(
PageXml,
"PcGts",
"http://schema.primaresearch.org/PAGE/gts/pagecontent/2019-07-15",
),
(
PageXml,
"PcGts",
"http://schema.primaresearch.org/PAGE/gts/pagecontent/2013-07-15",
),
(Alto, "alto", "http://www.loc.gov/standards/alto/ns-v4#"),
(Alto, "alto", "http://www.loc.gov/standards/alto/ns-v3#"),
(Alto, "alto", "http://www.loc.gov/standards/alto/ns-v2#"),
(Alto, "alto", "http://schema.ccs-gmbh.com/ALTO"),
(
AbbyyXml,
"document",
"http://www.abbyy.com/FineReader_xml/FineReader10-schema-v1.xml",
),
(
AbbyyXml,
"document",
"http://www.abbyy.com/FineReader_xml/FineReader6-schema-v1.xml",
),
]
def sniff_content(tmp_path, datatype, content):
path = tmp_path / "input"
path.write_text(content, encoding="utf-8")
return datatype().sniff(str(path))
@pytest.mark.parametrize("datatype,root,namespace", XML_FORMATS)
@pytest.mark.parametrize("prefixed", [False, True])
@pytest.mark.parametrize("prolog", ["", '\ufeff<?xml version="1.0"?>\n<!-- OCR export -->\n'])
def test_xml_ocr_sniff(tmp_path, datatype, root, namespace, prefixed, prolog):
tag = f"ocr:{root}" if prefixed else root
xmlns = "xmlns:ocr" if prefixed else "xmlns"
# A prefix may end inside the document; only the root start tag is needed.
content = f"{prolog}<{tag}\n {xmlns}='{namespace}'>\n<unfinished"
assert sniff_content(tmp_path, datatype, content)
for other in (PageXml, Alto, AbbyyXml):
if other is not datatype:
assert not sniff_content(tmp_path, other, content)
@pytest.mark.parametrize("datatype,root,namespace", XML_FORMATS)
@pytest.mark.parametrize(
"template",
[
"<{root}/>",
'<{root} xmlns="urn:unrelated"/>',
'<wrong xmlns="{namespace}"/>',
'<outer><{root} xmlns="{namespace}"/></outer>',
'<!-- <{root} xmlns="{namespace}"/> -->',
'<{root} xmlns="{namespace}.invalid"/>',
'<{root} xmlns="{namespace}"',
'plain text <{root} xmlns="{namespace}"/>',
],
)
def test_xml_ocr_rejects_false_positives(tmp_path, datatype, root, namespace, template):
assert not sniff_content(tmp_path, datatype, template.format(root=root, namespace=namespace))
@pytest.mark.parametrize(
"content,expected",
[
(
'<html><body><div class="ocr_page" title="bbox 0 0 100 100"></div></body></html>',
True,
),
(
'<?xml version="1.0"?><html xmlns="http://www.w3.org/1999/xhtml"><div class="ocr_page"/>',
True,
),
("<!DOCTYPE html><HTML><DIV CLASS='extra ocr_page selected'>", True),
('<div\n class = "extra\tocr_page\nselected">', True),
("<div class=ocr_page>", True),
("<html><p>ocr_page</p></html>", False),
('<html><!-- <div class="ocr_page"> --></html>', False),
(
"<html><script>var example = '<div class=\"ocr_page\">';</script></html>",
False,
),
('<div class="ocr_page_extra">', False),
('<div id="ocr_page">', False),
('<meta name="ocr-capabilities" content="ocr_page ocrx_word">', False),
('<div class="ocr_page', False),
("", False),
],
)
def test_hocr_sniff(tmp_path, content, expected):
assert sniff_content(tmp_path, Hocr, content) is expected
@pytest.fixture(scope="module")
def registry():
return example_datatype_registry_for_sample()
@pytest.mark.parametrize("datatype,root,namespace", XML_FORMATS)
def test_xml_ocr_registry(tmp_path, registry, datatype, root, namespace):
path = tmp_path / "unknown.dat"
path.write_text(f'<?xml version="1.0"?><{root} xmlns="{namespace}"/>')
assert isinstance(registry.get_datatype_by_extension(datatype.file_ext), datatype)
assert isinstance(registry.get_datatype_by_extension(datatype.file_ext), GenericXml)
assert registry.get_mimetype_by_extension(datatype.file_ext) == "application/xml"
assert guess_ext(str(path), registry.sniff_order) == datatype.file_ext
@pytest.mark.parametrize("prolog", ["", '<?xml version="1.0"?>'])
def test_hocr_registry(tmp_path, registry, prolog):
path = tmp_path / "unknown.dat"
path.write_text(f'{prolog}<html><body><div class="ocr_page"></div></body></html>')
assert isinstance(registry.get_datatype_by_extension("hocr"), Hocr)
assert isinstance(registry.get_datatype_by_extension("hocr"), Html)
assert registry.get_mimetype_by_extension("hocr") == "text/html"
assert guess_ext(str(path), registry.sniff_order) == "hocr"
@pytest.mark.parametrize(
"content,extension",
[
('<?xml version="1.0"?><document/>', "xml"),
("<html><body>ordinary HTML</body></html>", "html"),
("", "txt"),
],
)
def test_generic_fallback(tmp_path, registry, content, extension):
path = tmp_path / "unknown.dat"
path.write_text(content)
assert guess_ext(str(path), registry.sniff_order) == extension
@pytest.mark.parametrize(
"filename,datatype",
[
("ocr_sample.page.xml", PageXml),
("ocr_sample.alto", Alto),
("ocr_sample.abbyy.xml", AbbyyXml),
("ocr_sample.hocr", Hocr),
],
)
def test_ocr_fixtures(tmp_path, registry, filename, datatype):
source = get_test_fname(filename)
file_prefix = FilePrefix(source)
assert datatype().sniff_prefix(file_prefix)
for other in (PageXml, Alto, AbbyyXml, Hocr):
if other is not datatype:
assert not other().sniff_prefix(file_prefix)
# Preserve BOMs and line endings, but remove the filename's format hint.
path = tmp_path / "unknown.dat"
with open(source, "rb") as fixture:
path.write_bytes(fixture.read())
assert guess_ext(str(path), registry.sniff_order) == datatype.file_ext
+13
View File
@@ -0,0 +1,13 @@
import pytest
from sqlalchemy.exc import IntegrityError
from tool_shed.webapp.model import User
from .._util import TestToolShedApp
def test_username_is_unique(shed_app: TestToolShedApp):
session = shed_app.model.context
session.add(User(email="a@galaxyproject.org", username="taken", password="x"))
session.add(User(email="b@galaxyproject.org", username="taken", password="x"))
with pytest.raises(IntegrityError):
session.flush()
@@ -1,11 +1,13 @@
<tool id="interactive_tool_tensorboard" tool_type="interactive" name="TensorBoard" version="2.21.0" profile="23.0">
<tool id="interactive_tool_tensorboard" tool_type="interactive" name="TensorBoard" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="23.0">
<icon src="tensorboard.png"/>
<description>Visualize and explore tensorboard logs from machine/deep learning experiments</description>
<macros>
<token name="@TOOL_VERSION@">2.21.0</token>
<token name="@VERSION_SUFFIX@">0</token>
<token name="@PORT@">6006</token>
</macros>
<requirements>
<container type="docker">quay.io/galaxy/tensorboard:2.21.0</container>
<container type="docker">quay.io/biocontainers/tensorboard:@TOOL_VERSION@</container>
</requirements>
<entry_points>
<entry_point name="TensorBoard" requires_domain="True">
@@ -53,7 +55,7 @@
<param name="infile" type="data" format="tfevents" label="TensorBoard event log" help="Select a TensorBoard event file."/>
</when>
<when value="collection">
<param name="infiles" type="data_collection" collection_type="list" format="tfevents" label="TensorBoard event logs" help="Select a list collection of TensorBoard event files. Each collection element is displayed as a separate TensorBoard run."/>
<param name="infiles" type="data_collection" collection_type="list" format="tfevents" label="TensorBoard event logs" help="Select a list collection of TensorBoard event files. Each collection element is loaded as a separate set of TensorBoard logs."/>
</when>
</conditional>
</inputs>
@@ -65,8 +67,9 @@
You can provide either a single TensorBoard event file or a list collection of
TensorBoard event files.
For list collections, each collection element is presented as a separate
TensorBoard run. Galaxy collection element identifiers are used as the run names.
For list collections, each collection element is loaded as a separate set of TensorBoard logs.
The Galaxy collection element identifier is used as the corresponding name in TensorBoard,
allowing logs from multiple training runs to be compared.
After starting the tool, open TensorBoard from Galaxy's active interactive tools.
The available dashboards depend on the data recorded in your event logs.