<p>I was able to spot the problem. I thought the Server I was working on had at least 256 RAM. Turns out it only had 64.
I think HybridScaffolding needs at least 128 RAM. So when I ran the whole HybridScaffolding script on a stronger Server (1000 RAM) it worked just fine without any problems :)</p>
<p>Edit: For the record, I also had to unzip the cmap.gz file because the RefAligner could not read it zipped.</p>

CC BY-SA 4.0
2022-11-03T10:00:48.150Z
2022-11-03T10:00:48.150Z
snakelake
<p>as the title says I´m trying to run <a href="https://bionanogenomics.com" rel="nofollow noreferrer">Bionanos</a> HybridScaffolding from the command line rather than using their own software interface. This is commercial software to primarily to identify genomewide cancer analysis but also has options for genome assembly.</p>
<p>I installed Perl and all the necessary packages to run the HybridScaffolding Perl script. According to their <a href="https://bionanogenomics.com/wp-content/uploads/2018/04/30205-Guidelines-for-Running-Bionano-Solve-Pipeline-on-Command-Line.pdf" rel="nofollow noreferrer">documentation</a> I started the script with the correct parameters.
After 2 minutes it stops giving me the following error:</p>
<pre><code>Beginning initial NGS CMAP to BioNano CMAP alignment...
Running command: /home/user/workflow/scripts/bionano/tools/pipeline/1.0/RefAligner/1.0/RefAligner 
-ref /home/user/results/bionano/fa2cmap/pac_bio_assembly_CTTAAG_0kb_0labels.cmap 
-i /home/user/data/bionano/bCalAnn1_Saphyr_DLE1.cmap.gz 
-o align0 -stdout -stderr -maxmem 128 -maxthreads 64 
-maxvirtmem 0 -maxmemIncrease 8 -RAmem 3 1 0.9 -M 1 3 -ScaleDelta 0.03 2 -ScaleDeltaBPP 
-hashScaleDelta 2 -res 2.6 -resSD 0.7 -FP 0.2 -FN 0.02 -sf 0.10 -sd 0.0 -sr 0.01 -se 
0.2 -extend 1 -outlier 0.0001 -endoutlier 0.001 -PVendoutlier -deltaX 12 -deltaY 12 
-xmapchim 12 -hashgen 5 11 2.4 1.4 0.05 3.0 1 1 1 -hash -hashdelta 27 -hashoffset 1 
-hashrange 0 -hashGrouped 6 11 -hashMultiMatch 50 2 -hashGC 300 -hashT2 1 -hashkeys 1 
-HSDrange 1.0 -insertThreads 4 -nosplit 2 -biaswt 0 -T 1e-10 -S -1000 -indel -PVres 2 
-rres 0.9 -outlierBC -xmapUnique 12 -AlignRes 2. -outlierExtend 12 24 -resEstimate -f 
-mres 0.9 -thetaScale 0.5 -KL 1.5 -KF 1.5 -Kmax 4 -MinFN 0.01 -MinFP 0.16 -MinSF 0.05 
-MaxSF 0.15 -MinSD 0.0 -MaxSD 0.0 -MinSR 0.007 -MaxSR 0.015 -MaxSE 0.5 -MinRes 2.0 
-MinResSD 0.7 -hashSD 0 1 -hashSR 0 1

ERROR: Cannot open align0.stdout: No such file or directory
</code></pre>
<p>For context: The HybridScaffolding script contains several scripts which are started automatically over time. One of these is the RefAligner script, which throws the error in this case.</p>
<p>I have a folder called align0 which lies inside the directory that the script is running, therefore I guess this is not the casual &quot;The path is missing&quot; issue..</p>
<p>Inside the Perl Script 'align0.stdout' appears two times:</p>
<pre><code># error check
if (errCheckRefAligner(&quot;align0.stdout&quot;, &quot;END of output&quot;, &quot;Initial alignment complete in <span class="math-container">$span.", "ERROR: Initial alignment cannot be completed.", 0) != 1)  {
    my $errMsg = "ERROR: Initial alignment cannot be completed.";
    printStatus(\*STATUS_FILE, "align0", $errMsg, 1);
} else  {
    printStatus(\*STATUS_FILE, "align0", "Done", 0);
} # RefAligner check
errCheckRefAligner("align0.stdout", "END of output", "Initial alignment complete in $</span>span.&quot;, &quot;ERROR: Initial alignment cannot be completed.&quot;, 1);
</code></pre>
<p>Sadly I don´t have any Perl knowledge at all. Does anyone have experience with Bionanos Software and/or knowledge of Perl and could explain to me what is happening inside this part of the script?</p>

CC BY-SA 4.0
2022-10-30T16:49:19.043Z
What operating system are you using? Are you sure the script can run on it? The error suggests perl is trying to open a file named `align0.stdout` for either reading or writing and that file doesn't exist. Since you are passing `align0` as an output file name with `-o align0` (I am guessing), then presumably the script will create `$outputName.stdout` somewhere. Does it work if you give a full path like `-o /home/user/data/bionano/align0`? Also, what directory are you running this from? D you have write permissions there?
terdon
CC BY-SA 4.0
2022-11-03T09:59:52.487Z
I´m working on a Debian Server. I was able to spot the problem. I thought the Server had at least 256 RAM. Turns out it had only 64. I think HybridScaffolding needs at least 128 RAM. So when I ran the whole HybridScaffolding Script on a stronger Server (1000 RAM) it worked just fine without any problems :)
snakelake
<perl>
Running Bionano´s HybridScaffolding from the command line [Error: align0.stdout]
# Running Bionano´s HybridScaffolding from the command line [Error: align0.stdout]

(Asked by: username_0 on 2022-10-30)

as the title says I´m trying to run Bionanos HybridScaffolding from the command line rather than using their own software interface. This is commercial software to primarily to identify genomewide cancer analysis but also has options for genome assembly.
I installed Perl and all the necessary packages to run the HybridScaffolding Perl script. According to their documentation I started the script with the correct parameters.
After 2 minutes it stops giving me the following error:
Beginning initial NGS CMAP to BioNano CMAP alignment...
Running command: /home/user/workflow/scripts/bionano/tools/pipeline/1.0/RefAligner/1.0/RefAligner 
-ref /home/user/results/bionano/fa2cmap/pac_bio_assembly_CTTAAG_0kb_0labels.cmap 
-i /home/user/data/bionano/bCalAnn1_Saphyr_DLE1.cmap.gz 
-o align0 -stdout -stderr -maxmem 128 -maxthreads 64 
-maxvirtmem 0 -maxmemIncrease 8 -RAmem 3 1 0.9 -M 1 3 -ScaleDelta 0.03 2 -ScaleDeltaBPP 
-hashScaleDelta 2 -res 2.6 -resSD 0.7 -FP 0.2 -FN 0.02 -sf 0.10 -sd 0.0 -sr 0.01 -se 
0.2 -extend 1 -outlier 0.0001 -endoutlier 0.001 -PVendoutlier -deltaX 12 -deltaY 12 
-xmapchim 12 -hashgen 5 11 2.4 1.4 0.05 3.0 1 1 1 -hash -hashdelta 27 -hashoffset 1 
-hashrange 0 -hashGrouped 6 11 -hashMultiMatch 50 2 -hashGC 300 -hashT2 1 -hashkeys 1 
-HSDrange 1.0 -insertThreads 4 -nosplit 2 -biaswt 0 -T 1e-10 -S -1000 -indel -PVres 2 
-rres 0.9 -outlierBC -xmapUnique 12 -AlignRes 2. -outlierExtend 12 24 -resEstimate -f 
-mres 0.9 -thetaScale 0.5 -KL 1.5 -KF 1.5 -Kmax 4 -MinFN 0.01 -MinFP 0.16 -MinSF 0.05 
-MaxSF 0.15 -MinSD 0.0 -MaxSD 0.0 -MinSR 0.007 -MaxSR 0.015 -MaxSE 0.5 -MinRes 2.0 
-MinResSD 0.7 -hashSD 0 1 -hashSR 0 1

ERROR: Cannot open align0.stdout: No such file or directory

For context: The HybridScaffolding script contains several scripts which are started automatically over time. One of these is the RefAligner script, which throws the error in this case.
I have a folder called align0 which lies inside the directory that the script is running, therefore I guess this is not the casual "The path is missing" issue..
Inside the Perl Script 'align0.stdout' appears two times:
# error check
if (errCheckRefAligner("align0.stdout", "END of output", "Initial alignment complete in $span.", "ERROR: Initial alignment cannot be completed.", 0) != 1)  {
    my $errMsg = "ERROR: Initial alignment cannot be completed.";
    printStatus(\*STATUS_FILE, "align0", $errMsg, 1);
} else  {
    printStatus(\*STATUS_FILE, "align0", "Done", 0);
} # RefAligner check
errCheckRefAligner("align0.stdout", "END of output", "Initial alignment complete in $span.", "ERROR: Initial alignment cannot be completed.", 1);

Sadly I don´t have any Perl knowledge at all. Does anyone have experience with Bionanos Software and/or knowledge of Perl and could explain to me what is happening inside this part of the script?

**Tags:** perl
> **Comments:**
> **username_1**: What operating system are you using? Are you sure the script can run on it? The error suggests perl is trying to open a file named `align0.stdout` for either reading or writing and that file doesn't exist. Since you are passing `align0` as an output file name with `-o align0` (I am guessing), then presumably the script will create `$outputName.stdout` somewhere. Does it work if you give a full path like `-o /home/user/data/bionano/align0`? Also, what directory are you running this from? D you have write permissions there?  
> **username_0**: I´m working on a Debian Server. I was able to spot the problem. I thought the Server had at least 256 RAM. Turns out it had only 64. I think HybridScaffolding needs at least 128 RAM. So when I ran the whole HybridScaffolding Script on a stronger Server (1000 RAM) it worked just fine without any problems :)  

---

## 1 answers

### Answer by username_0 on 2022-11-03. Score: 2 | Accepted answer

I was able to spot the problem. I thought the Server I was working on had at least 256 RAM. Turns out it only had 64.
I think HybridScaffolding needs at least 128 RAM. So when I ran the whole HybridScaffolding script on a stronger Server (1000 RAM) it worked just fine without any problems :)

Edit: For the record, I also had to unzip the cmap.gz file because the RefAligner could not read it zipped.


---

