Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update source_urls for Velvet 1.2.10 #18237

Merged

Conversation

branfosj
Copy link
Member

(created using eb --new-pr)

@boegel boegel added the bug fix label Jun 29, 2023
@boegel boegel added this to the next release (4.7.3?) milestone Jun 29, 2023
@boegel
Copy link
Member

boegel commented Jun 29, 2023

@branfosj Is there an actual difference in contents of the source tarball?
Should we retain the old checksum as valid?

@branfosj
Copy link
Member Author

@branfosj Is there an actual difference in contents of the source tarball? Should we retain the old checksum as valid?

I do not have the old version to check with. We are having a filename change, so we would have to do something more complicated...

@branfosj
Copy link
Member Author

Test report by @branfosj
SUCCESS
Build succeeded for 1 out of 1 (1 easyconfigs in total)
bear-pg0105u03a.bear.cluster - Linux RHEL 8.6, x86_64, Intel(R) Xeon(R) Platinum 8360Y CPU @ 2.40GHz (icelake), Python 3.6.8
See https://gist.github.com/branfosj/06699978b252e98a69aae0d6a4b93132 for a full test report.

@branfosj
Copy link
Member Author

branfosj commented Jun 29, 2023

@boegelbot please test @ jsc-zen2
EB_ARGS="Velvet-1.2.10-GCC-11.2.0-mt-kmer_191.eb"

@boegelbot
Copy link
Collaborator

@branfosj: Request for testing this PR well received on jsczen2l1.int.jsc-zen2.easybuild-test.cluster

PR test command 'EB_PR=18237 EB_ARGS="Velvet-1.2.10-GCC-11.2.0-mt-kmer_191.eb" /opt/software/slurm/bin/sbatch --mem-per-cpu=4000M --job-name test_PR_18237 --ntasks=8 ~/boegelbot/eb_from_pr_upload_jsc-zen2.sh' executed!

  • exit code: 0
  • output:
Submitted batch job 2922

Test results coming soon (I hope)...

- notification for comment with ID 1613564911 processed

Message to humans: this is just bookkeeping information for me,
it is of no use to you (unless you think I have a bug, which I don't).

@boegelbot
Copy link
Collaborator

Test report by @boegelbot
SUCCESS
Build succeeded for 1 out of 1 (1 easyconfigs in total)
jsczen2c1.int.jsc-zen2.easybuild-test.cluster - Linux Rocky Linux 8.5, x86_64, AMD EPYC 7742 64-Core Processor (zen2), Python 3.6.8
See https://gist.github.com/boegelbot/b1548c63aa80b547bc1ded41acb7414f for a full test report.

@boegel
Copy link
Member

boegel commented Jun 29, 2023

Code is not exactly the same as old source tarball, but it looks like we don't have many options here...

 $ diff -ru velvet_1.2.10 velvet-1.2.10
diff -ru velvet_1.2.10/Makefile velvet-1.2.10/Makefile
--- velvet_1.2.10/Makefile	2013-10-17 18:03:39.000000000 +0200
+++ velvet-1.2.10/Makefile	2014-08-15 18:13:23.000000000 +0200
@@ -3,8 +3,8 @@
 DEBUG = -g
 LIBS = -lm
 OPT = -O3
-MAXKMERLENGTH=31
-CATEGORIES=2
+MAXKMERLENGTH?=31
+CATEGORIES?=2
 DEF = -D MAXKMERLENGTH=$(MAXKMERLENGTH) -D CATEGORIES=$(CATEGORIES)
 PDFLATEX_VERSION := $(shell pdflatex --version 2> /dev/null)

diff -ru velvet_1.2.10/src/correctedGraph.c velvet-1.2.10/src/correctedGraph.c
--- velvet_1.2.10/src/correctedGraph.c	2013-10-17 18:03:39.000000000 +0200
+++ velvet-1.2.10/src/correctedGraph.c	2014-08-15 18:13:23.000000000 +0200
@@ -2094,9 +2094,11 @@
 		if (isTerminal(slowMarker))
 			slowLength = finalLength;
 		else {
-			slowLength =
-			    slowToFastMapping[getPassageMarkerFinish
-					      (slowMarker) - 1];
+			if(getPassageMarkerFinish(slowMarker) != 0)
+				slowLength = slowToFastMapping[getPassageMarkerFinish(slowMarker) - 1];
+			else
+				slowLength = slowToFastMapping[0];
+
 			if (slowLength < slowConstraint)
 				slowLength = slowConstraint;
 		}
diff -ru velvet_1.2.10/src/graph.c velvet-1.2.10/src/graph.c
--- velvet_1.2.10/src/graph.c	2013-10-17 18:03:39.000000000 +0200
+++ velvet-1.2.10/src/graph.c	2014-08-15 18:13:23.000000000 +0200
@@ -906,7 +906,7 @@
 	twinDestination->length = newLength;
 }

-static void catDescriptors(Descriptor * descr, Coordinate destinationLength, Descriptor * copy, Coordinate sourceLength)
+static void catDescriptors(Descriptor * descr, Coordinate destinationLength, Descriptor * copy, Coordinate sourceLength)
 {
 	Coordinate index;
 	Nucleotide nucleotide;
@@ -917,7 +917,7 @@
 	}
 }

-static void reverseCatDescriptors(Descriptor * descr, Coordinate destinationLength, Descriptor * copy, Coordinate sourceLength, Coordinate totalLength)
+static void reverseCatDescriptors(Descriptor * descr, Coordinate destinationLength, Descriptor * copy, Coordinate sourceLength, Coordinate totalLength)
 {
 	Coordinate shift = totalLength - destinationLength - sourceLength;
 	Coordinate index;
@@ -2052,7 +2052,7 @@
 	short short_var;
 	char c;

-	if (file == NULL)
+	if (file == NULL)
 		exitErrorf(EXIT_FAILURE, true, "Could not open %s", filename);

 	velvetLog("Reading graph file %s\n", filename);
@@ -2204,9 +2204,9 @@
 				velvetLog
 				    ("ERROR: reading in graph - only %d items read for line '%s'",
 				     sCount, line);
-#ifdef DEBUG
+#ifdef DEBUG
 				abort();
-#endif
+#endif
 				exit(1);
 			}
 			newMarker =
@@ -2404,7 +2404,7 @@
 #endif
 				}
 			}
-
+
 			index++;
 		}

@@ -2506,7 +2506,7 @@
 		twin = node->twinNode;
 		twin->length = node->length;
 		twin->descriptor =
-			callocOrExit(arrayLength, Descriptor);
+			callocOrExit(arrayLength, Descriptor);

 		index = 0;
 		while ((c = getc(file)) != '\n') {
@@ -3145,9 +3145,13 @@
 	}

 	free(sourceArray);
-	graph->nodeReads[sourceID] = newArray;
 	graph->nodeReadCounts[sourceID] = newLength;

+	if(newLength > 0)
+		graph->nodeReads[sourceID] = newArray;
+	else
+		graph->nodeReads[sourceID] = NULL;
+
 	*length = mergeLength;
 	return mergeArray;
 }
@@ -3275,9 +3279,13 @@
 	}

 	free(sourceArray);
-	graph->nodeReads[sourceID] = newArray;
 	graph->nodeReadCounts[sourceID] = newLength;

+	if(newLength > 0)
+		graph->nodeReads[sourceID] = newArray;
+	else
+		graph->nodeReads[sourceID] = NULL;
+
 	*length = mergeLength;
 	return mergeArray;
 }
@@ -3321,8 +3329,13 @@
 			sourceIndex++;
 		}

-		graph->nodeReads[targetID] = mergeArray;
 		graph->nodeReadCounts[targetID] = sourceLength;
+
+		if(sourceLength > 0)
+		    graph->nodeReads[targetID] = mergeArray;
+		else
+		    graph->nodeReads[targetID] = NULL;
+
 		return;
 	}

@@ -3402,8 +3415,12 @@
 	}

 	free(targetArray);
-	graph->nodeReads[targetID] = mergeArray;
 	graph->nodeReadCounts[targetID] = mergeLength;
+
+	if(mergeLength > 0)
+		graph->nodeReads[targetID] = mergeArray;
+	else
+		graph->nodeReads[targetID] = NULL;
 }

 static inline Coordinate min(Coordinate A, Coordinate B)
@@ -3437,8 +3454,13 @@

 	if (targetLength == 0) {
 		free(targetArray);
-		graph->nodeReads[targetID] = sourceArray;
 		graph->nodeReadCounts[targetID] = sourceLength;
+
+		if(sourceLength > 0)
+			graph->nodeReads[targetID] = sourceArray;
+		else
+			graph->nodeReads[targetID] = NULL;
+
 		return;
 	}

@@ -3548,9 +3570,13 @@
 	}

 	free(targetArray);
-	graph->nodeReads[targetID] = mergeArray;
 	graph->nodeReadCounts[targetID] = mergeLength;

+	if(mergeLength > 0)
+		graph->nodeReads[targetID] = mergeArray;
+	else
+		graph->nodeReads[targetID] = NULL;
+
 	free(sourceArray);
 }

@@ -3693,12 +3719,20 @@
 	}

 	free(targetArray);
-	graph->nodeReads[targetID] = mergeArray;
 	graph->nodeReadCounts[targetID] = mergeLength;

+	if(mergeLength > 0)
+		graph->nodeReads[targetID] = mergeArray;
+	else
+		graph->nodeReads[targetID] = NULL;
+
 	free(sourceArray);
-	graph->nodeReads[sourceID] = mergeArray2;
 	graph->nodeReadCounts[sourceID] = mergeLength;
+
+	if(mergeLength > 0)
+		graph->nodeReads[sourceID] = mergeArray2;
+	else
+		graph->nodeReads[sourceID] = NULL;
 }

 void shareReadStarts(Node * target, Node * source, Graph * graph)
@@ -3973,7 +4007,7 @@
 		nucleotide = getNucleotideInDescriptor(twin->descriptor, index);
 		writeNucleotideInDescriptor(nucleotide, array, index + shift);
 	}
-
+
 	free(twin->descriptor);
 	twin->descriptor = array;
 }
diff -ru velvet_1.2.10/src/scaffold.h velvet-1.2.10/src/scaffold.h
--- velvet_1.2.10/src/scaffold.h	2013-10-17 18:03:39.000000000 +0200
+++ velvet-1.2.10/src/scaffold.h	2014-08-15 18:13:23.000000000 +0200
@@ -18,7 +18,7 @@
     Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

 */
-#ifndef _SSCAFFOLD_H_
+#ifndef _SCAFFOLD_H_
 #define _SCAFFOLD_H_

 typedef struct connection_st Connection;

@boegel boegel changed the title upate source_urls for Velvet upate source_urls for Velvet 1.2.10 Jun 29, 2023
Copy link
Member

@boegel boegel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@boegel boegel changed the title upate source_urls for Velvet 1.2.10 update source_urls for Velvet 1.2.10 Jun 29, 2023
@boegel
Copy link
Member

boegel commented Jun 29, 2023

Test report by @boegel
SUCCESS
Build succeeded for 3 out of 3 (3 easyconfigs in total)
node3169.skitty.os - Linux RHEL 8.6, x86_64, Intel(R) Xeon(R) Gold 6140 CPU @ 2.30GHz (skylake_avx512), Python 3.6.8
See https://gist.github.com/boegel/50fb085d32b459a5d935ce9b197db9eb for a full test report.

@boegel
Copy link
Member

boegel commented Jun 29, 2023

Going in, thanks @branfosj!

@boegel boegel merged commit 664c17b into easybuilders:develop Jun 29, 2023
5 checks passed
@boegel boegel added the change label Jun 29, 2023
@branfosj branfosj deleted the 20230629180927_new_pr_Velvet1210 branch June 29, 2023 19:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants