Smithwaterman CUDA code


i am learning CUDA.

can anyone share the smith waterman basic implementation in CUDA?
facing difficulty in implementation.


is googling by “smith waterman CUDA” not enough?

Have you had a chance to look at CUDASW++?

since i am learning cuda i want basic implementation.
i got these code, but i feel little tough to understand.

plz help

One can learn a lot by studying and experimenting with an existing implementation such as CUDASW++. The alternative approach to learning is to start with the basics of an algorithm (see Wikipedia for a basic explanation of Smith-Waterman), create a rudimentary but functional implementation, and work incrementally your way forward towards higher performance and more sophisticated implementations.

Depending on your programming and bioinformatics background, either way may require weeks or months of continuous work until you get a good grasp of the topic (at least that is the time I myself need to acquire a good working knowledge in an area of science I have not been previously familiar with). Identify and familiarize yourself with relevant papers on the subject, Google Scholar can help a lot with that.

In addition to the njuffa post, as far as I know, the state-of-the-art in SW for CUDA is from NVIDIA:
All the project is open-source so you can also review the code implementation.

Once you are familiar with the topic I recommend to you review the most relevant SIMD publications of the area to take algorithmic ideas:
[1] Striped Smith–Waterman speeds database searches six times over other SIMD implementations.
[2] Using video-oriented instructions to speed up sequence comparison.
[3] Six-fold speed-up of Smith–Waterman sequence database searches using parallel processing on common microprocessors.
[4] Faster Smith-Waterman database searches with inter-sequence SIMD parallelisation.

Also the thread-cooperative SW-Gotoh Jacopo’s implementation could be a good inspirational source:

I did not mention NVBIO since the OP seems to be looking for source code they can study, and I do not know whether NVBIO ships with source code. Does it?

For sure, all the project is under BSD license, you can find the source-code of all the project here:

Here the SW-Gotoh implementation: