Skip to content

Commit

Permalink
Another fix needed for new SMRTLink. May not be the last.
Browse files Browse the repository at this point in the history
  • Loading branch information
tbooth committed Jan 28, 2025
1 parent 460fc2f commit 798673c
Show file tree
Hide file tree
Showing 4 changed files with 203 additions and 7 deletions.
2 changes: 1 addition & 1 deletion compile_cell_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def compile_json_reports(reports_dict, metadata_xml, lima_counts=None):
# Let's load it up. This will be a long function.
reports['Run']['Movie Time (hours)'] = metadata_xml['movie_time']
reports['Run']['Library type'] = metadata_xml['application'] # Maybe?
reports['Run']['Adaptive loading'] = metadata_xml['adaptive_loading']
reports['Run']['Adaptive loading'] = "{}".format(metadata_xml['adaptive_loading'])
reports['Run']['SMRT Cell Lot Number'] = metadata_xml['smrt_cell_lot_number']
reports['Run']['Well Sample Name'] = metadata_xml['ws_name']
reports['Run']['Well name'] = metadata_xml['run_slot']
Expand Down
6 changes: 3 additions & 3 deletions smrtino/ParseXML.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ def _get_automation_parameters(root):
if k in res:
raise KeyError(f"AutomationParameter {k} is repeated in XML.")

if dtype == "Boolean":
# But at least some booleans are tagged as strings
if dtype == "Boolean" or k in ["DynamicLoadingCognate"]:
# At least some booleans are tagged as strings, hence the special case
res[k] = val == "True"
elif dtype == "String":
res[k] = val
Expand Down Expand Up @@ -265,7 +265,7 @@ def get_metadata_info2(xmlfile):
root.find('.//pbmeta:OnPlateLoadingConcentration', _ns).text )

# software versions
vi = { e.attrib['Name']: e.attrib['Version'] for e in
vi = { e.attrib['Name']: e.attrib.get('Version', 'unknown') for e in
root.findall('.//pbmeta:ComponentVersions/pbmeta:VersionInfo', _ns) }
run_info['version_ics'] = vi['ics']
run_info['version_chemistry'] = vi['chemistry']
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@
<?xml version="1.0" encoding="utf-8"?>
<PacBioDataModel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Version="4.0.1" xmlns="http://pacificbiosciences.com/PacBioDataModel.xsd">
<ExperimentContainer CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00">
<InvestigatorName>Default</InvestigatorName>
<CreatedDate>2025-01-21</CreatedDate>
<Runs>
<Run Name="Run_21_Jan_2025" Description="UltraLow_And_Kinnex" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" UniqueId="8d1bbb56-08a6-4984-a43c-9a7efae6edd6" MetaType="Run" TimeStampedName="r84140_20250121_143858" Status="Running" ChipType="25mChip" InstrumentType="Revio" CreatedBy="rfoster2" StartedBy="unknown" WhenStarted="2025-01-21T14:39:58.7980482Z">
<Outputs>
<SubreadSets>
<SubreadSet Name="33461BMpool01-Cell3" CreatedAt="2025-01-21T14:36:48.598Z" UniqueId="898ad30a-82dc-441f-a6cb-fdf2784656b0" MetaType="SubreadSetCollection" TimeStampedName="84140-SubreadSetCollection-2025-01-21T14:38:58.642Z" xmlns="http://pacificbiosciences.com/PacBioDatasets.xsd">
<ExternalResources xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">
<ExternalResource UniqueId="529a1d87-4f5f-4196-b17f-fe51e58758b4" MetaType="ExternalResource" TimeStampedName="84140-ExternalResource-2025-01-21T14:38:58.642Z" />
</ExternalResources>
<DataSetMetadata>
<TotalLength>0</TotalLength>
<NumRecords>0</NumRecords>
<Collections xmlns="http://pacificbiosciences.com/PacBioCollectionMetadata.xsd">
<CollectionMetadata CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" UniqueId="898ad30a-82dc-441f-a6cb-fdf2784656b0" MetaType="CollectionMetadata" TimeStampedName="84140-CollectionMetadata-2025-01-21T14:38:58.642Z" Context="m84140_250121_185015_s3" Status="PostPrimaryPending" InstrumentId="84140" InstrumentName="Obelix">
<MultiJobId>0</MultiJobId>
<ProjectId>1</ProjectId>
<ConsensusReadSetRef UniqueId="79c79af3-fcd8-4250-b40c-003a80ed7530" />
<RunDetails>
<TimeStampedName>r84140_20250121_143858</TimeStampedName>
<Name>Run_21_Jan_2025</Name>
<CreatedBy>rfoster2</CreatedBy>
<WhenCreated>2025-01-21T14:36:48.598Z</WhenCreated>
<StartedBy>unknown</StartedBy>
<WhenStarted>2025-01-21T14:39:58.7980482Z</WhenStarted>
</RunDetails>
<WellSample Name="33461BMpool01" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00">
<WellName>C01</WellName>
<Application>masSeqForIsoSeq</Application>
<LibraryType>masSeq</LibraryType>
<Concentration>0</Concentration>
<OnPlateLoadingConcentration>185</OnPlateLoadingConcentration>
<InsertSize>10000</InsertSize>
<IsoSeq>false</IsoSeq>
<IsCCS>true</IsCCS>
<SampleReuseEnabled>false</SampleReuseEnabled>
<StageHotstartEnabled>false</StageHotstartEnabled>
<SizeSelectionEnabled>false</SizeSelectionEnabled>
<UseCount>0</UseCount>
<DNAControlComplex>Sequencing control</DNAControlComplex>
<BioSamples xmlns="http://pacificbiosciences.com/PacBioSampleInfo.xsd">
<BioSample Name="33461BMpool01" />
</BioSamples>
</WellSample>
<Automation Name="Workflow_Kestrel.py">
<AutomationParameters xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">
<AutomationParameter Name="MovieLength" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Double" SimpleValue="1800.0" />
<AutomationParameter Name="DynamicLoadingCognate" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="String" SimpleValue="True" />
<AutomationParameter Name="ReuseCell" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="TotalSamples" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Int32" SimpleValue="1" />
<AutomationParameter Name="InsertSize" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Int32" SimpleValue="10000" />
<AutomationParameter Name="LSI_CellPrep" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="PCDinPlate" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="UsePredictiveLoadingBuffer" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="CollectionNumber" ValueDataType="Int32" SimpleValue="2" />
<AutomationParameter Name="BindingKitPartNumber" ValueDataType="String" SimpleValue="102-739-100" />
<AutomationParameter Name="TipSearchMaxDuration" ValueDataType="Int32" SimpleValue="576" />
<AutomationParameter Name="PPAEstimatedDuration" ValueDataType="Double" SimpleValue="840" />
<AutomationParameter Name="PPAMinDuration" ValueDataType="Double" SimpleValue="660.1800000000001" />
<AutomationParameter Name="PPAMaxDuration" ValueDataType="Double" SimpleValue="1019.82" />
<AutomationParameter Name="PPATimeout" ValueDataType="Double" SimpleValue="3900" />
<AutomationParameter Name="CCSOverheadDurationMinutesPerUmyGBase" ValueDataType="Double" SimpleValue="0.9" />
<AutomationParameter Name="SNRCut" ValueDataType="Double" SimpleValue="1.5" />
<AutomationParameter Name="HQRFMethod" ValueDataType="String" SimpleValue="N2" />
<AutomationParameter Name="DynamicLoadingTotalTimeSeconds" ValueDataType="Double" SimpleValue="792.4355563" />
<AutomationParameter Name="DynamicLoadingTimeZero" ValueDataType="String" SimpleValue="1/21/2025 7:06:09 PM" />
<AutomationParameter Name="DynamicLoadingServiceStartTime" ValueDataType="String" SimpleValue="1/21/2025 7:15:48 PM" />
<AutomationParameter Name="DynamicLoadingServiceTotalTimeSeconds" ValueDataType="Double" SimpleValue="213.7700806" />
</AutomationParameters>
<Defaults xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd" />
</Automation>
<CollectionNumber>2</CollectionNumber>
<CellIndex>2</CellIndex>
<SetNumber>0</SetNumber>
<CellPac Name="Revio SMRT Cell tray" Description="Tray of 4 Revio SMRT Cells for sequencing on the Revio system." Version="1.0" PartNumber="102-202-200" LotNumber="1000003526" LabelNumber="EA156579" Barcode="EA156579" ExpirationDate="2026-04-07" MovieTimeGrade="LR">
<ChipLayout xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">KestrelRTO2</ChipLayout>
</CellPac>
<ControlKit Name="Sequencing control" Description="A fixed 11 kb DNA template bound to polymerase for use as a spike-in control." Tags="Control Kit, CCK" Version="1.0" PartNumber="102-798-000" LotNumber="Lxxxxx" Barcode="Lxxxxx102798000123199" ExpirationDate="2099-12-31" ChipType="25mChip">
<CustomSequence xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">&gt;left_adapter\nTAGAGAGAGAAAAGGAGGAGGAGGCAACAACAACAACTCTCTCTA\n&gt;right_adapter\nTAGAGAGAGAAAAGGAGGAGGAGGCAACAACAACAACTCTCTCTA\n&gt;custom_sequence\nTCCCGACTGGAAAGCGGGCAGTGAGCGCAACGCAATTAATGTGAGTTAGCTCACTCATTAGGCACCCCAGGCTTTACACTTTATGCTTCCGGCTCGTATGTTGTGTGGAATTGTGAGCGGATAACAATTTCACACAGGAAACAGCTATGACCATGATTACGCCAAGCTTGCATGCCTGCAGGTCGACTCTAGAGGATCCCCCTGGCCGCATCCAGACTCAAATCAACGACCAGATCGCCTACCGGTTCAGCCATACCGGACTCCTCCTGCGATCCCTTCTGATACTGTCATCAGCATTACGTCATCCTCCGTCATGTCCGCCACATCCGGGGAAGCGGGGATAACTTCATTCCCGTCCGGGCCAAAGCGGACACCTCCGGCAAGCCCTGCCGCTTTCTGCAGCAGGCTCGCCAGCAGCGCACTGAGATCCAGCTGCCAGCGGGAAATACTGATGCGCAGCGCCGCCAGCGCATAAACGAAGCAGTCGAGTGCCTCATTGCGTCGCTTTTTGCTGTCCCACAGTATTTTTTTCCTGCCATCCACCCATTTTTCGACCTGCTCTTCAGCAGTCAGCTGCTGCGCTTCGGTCAGATCAAAAATAGGGTACCGAGCTCGAATTCACTGGCCGTCGTTTTACAACGTCGTGACTGGGAAAACCCTGGCGTTACCCAACTTAATCGCCTTGCAGCACATCCCCCTTTCGCCAGCTGGCGTAATAGCGAAGAGGCCCGCACCGATCGCCCTTCCCAACAGTTGCGCAGCCTGAATGGCGAATGGCGCCTGATGCGGTATTTTCTCCTTA</CustomSequence>
</ControlKit>
<TemplatePrepKit Name="Kinnex prep kit" Description="Reagents for preparing Kinnex SMRTbell libraries." Tags="Template Prep Kit, TPK" Version="1.0" PartNumber="999-999-101" LotNumber="Lxxxxx" Barcode="Lxxxxx999999101123199" ExpirationDate="2099-12-31" ChipType="25mChip" MinInsertSize="500" MaxInsertSize="20000">
<LeftAdaptorSequence xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">CCGCTCTCTCACTTTCGTGAGAGAGCGG</LeftAdaptorSequence>
<RightAdaptorSequence xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">CAACAACAACAACGGAGGAGGAGGAAAAG</RightAdaptorSequence>
<RightPrimerSequence xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd">aacggaggaggagga</RightPrimerSequence>
</TemplatePrepKit>
<BindingKit Name="Revio polymerase kit" Description="Reagents for binding polymerase to SMRTbell libraries for sequencing on the Revio system." Tags="Binding Kit, BDK" Version="1.0" PartNumber="102-739-100" LotNumber="Lxxxxx" Barcode="Lxxxxx102739100123199" ExpirationDate="2099-12-31" ChipType="25mChip" InstrumentType="Revio" />
<SequencingKitPlate Name="Revio sequencing plate" Description="Sequencing reagents supporting 4 Revio SMRT Cells." Tags="Sequencing Kit, SQK" Version="1.0" PartNumber="102-118-800" LotNumber="037117" LabelNumber="00078" PlateNumber="1" Barcode="037117102118800071125" ExpirationDate="2025-07-11" ChipType="25mChip" InstrumentType="Revio" MaxCollections="4" ActiveHours="4.497851218611111" ActiveHoursLimit="336" NumOilTubes="0" NumOseTubes="0" SupportsDynamicLoading="true" />
<Primary>
<AutomationName>SequelAlpha</AutomationName>
<ConfigFileName>SqlPoC_SubCrf_2C2A-t2.xml</ConfigFileName>
<SequencingCondition>DefaultPrimarySequencingCondition</SequencingCondition>
<CCSOptions>
<ExecutionMode>OnInstrument</ExecutionMode>
<IncludeKinetics>true</IncludeKinetics>
</CCSOptions>
<OutputOptions>
<ResultsFolder>r84140_20250121_143858/1_C01/</ResultsFolder>
<CollectionPathUri>/mnt/lustre/gseg/smrtlink/sequel_seqdata/r84140_20250121_143858/1_C01/</CollectionPathUri>
<CopyFiles>
<CollectionFileCopy>Bam</CollectionFileCopy>
<CollectionFileCopy>Fasta</CollectionFileCopy>
</CopyFiles>
<Readout>Bases_Without_QVs</Readout>
<MetricsVerbosity>Minimal</MetricsVerbosity>
<TransferResource>
<Id>6849e47e-ddfa-4dfb-8b76-c8ecd325129a</Id>
<TransferScheme>SRS</TransferScheme>
<Name>Revio Transfer Scheme 1</Name>
<Description>Revio to edgen-smrtlink.epcc.ed.ac.uk</Description>
<DestPath>/mnt/lustre/gseg/smrtlink/sequel_seqdata</DestPath>
</TransferResource>
</OutputOptions>
</Primary>
<Secondary>
<AutomationName>SMRTLinkRunDesign</AutomationName>
<AutomationParameters>
<AutomationParameter Name="SourceId" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="String" SimpleValue="smrtlink-rest-api" />
<AutomationParameter Name="CCS" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="CCSMode" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="String" SimpleValue="OnInstrument" />
<AutomationParameter Name="Kinetics" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="AllReads" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="Demultiplex" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="DemultiplexMode" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="String" SimpleValue="None" />
<AutomationParameter Name="FullResolutionBaseQual" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="SubreadToHiFiPileup" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="ByStrand" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="CpG" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="True" />
<AutomationParameter Name="AAV" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="Heteroduplex" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Boolean" SimpleValue="False" />
<AutomationParameter Name="SampleSubreadsPct" CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="Int32" SimpleValue="0" />
</AutomationParameters>
</Secondary>
<UserDefinedFields>
<DataEntities Name=" LIMS_IMPORT " CreatedAt="2025-01-21T14:36:48.598Z" ModifiedAt="0001-01-01T00:00:00" ValueDataType="String" SimpleValue="DefaultUserDefinedFieldLIMS" xmlns="http://pacificbiosciences.com/PacBioBaseDataModel.xsd" />
</UserDefinedFields>
<ComponentVersions>
<VersionInfo Name="ics" Version="13.3.0.253824" />
<VersionInfo Name="iui" Version="Unknown" />
<VersionInfo Name="chemistry" Version="13.3.0.249246" />
<VersionInfo Name="pa" Version="13.3.0.253824" />
<VersionInfo Name="basecaller" Version="13.0.0" />
<VersionInfo Name="baz2bam" Version="release/kestrel-13.3_664e9a3f3e1bb4eac405607fd1fd4bd1485c1cd8-dirty" />
<VersionInfo Name="ccs" />
<VersionInfo Name="jasmine" />
<VersionInfo Name="lima" />
<VersionInfo Name="pa-cal" Version="13.0.0.664e9a3f3e1bb4eac405607fd1fd4bd1485c1cd8-dirty" />
<VersionInfo Name="pa-wsgo" Version="13.3.1-9ec05e51395b7b84e8c0be495284d3bef63c295f" />
<VersionInfo Name="pawnee" Version="pawnee 1.6.3 (commit v1.6.2-1-g9acbe9d)" />
<VersionInfo Name="reducestats" Version="release/kestrel-13.3_664e9a3f3e1bb4eac405607fd1fd4bd1485c1cd8-dirty" />
<VersionInfo Name="samtools" />
<VersionInfo Name="smrtinub" Version="25.1.0.257715" />
<VersionInfo Name="smrtimisc" Version="25.1.0.257715" />
<VersionInfo Name="smrtlink-analysisservices-gui" Version="25.1.0.257715" />
<VersionInfo Name="smrttools" Version="25.1.0.257715" />
<VersionInfo Name="smrtlink" Version="25.1.0.257715" />
</ComponentVersions>
</CollectionMetadata>
</Collections>
</DataSetMetadata>
</SubreadSet>
</SubreadSets>
</Outputs>
</Run>
</Runs>
</ExperimentContainer>
</PacBioDataModel>
Loading

0 comments on commit 798673c

Please sign in to comment.