Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cjdoris/edlib.jl
Julia bindings for the edlib string alignment library
https://github.com/cjdoris/edlib.jl
Last synced: 24 days ago
JSON representation
Julia bindings for the edlib string alignment library
- Host: GitHub
- URL: https://github.com/cjdoris/edlib.jl
- Owner: cjdoris
- Created: 2020-03-05T14:26:13.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-03-18T14:06:08.000Z (over 4 years ago)
- Last Synced: 2024-10-09T06:18:07.176Z (28 days ago)
- Language: Julia
- Homepage: https://juliahub.com/docs/Edlib/
- Size: 15.6 KB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Edlib.jl
Julia bindings for the [edlib string alignment library](https://github.com/Martinsos/edlib), including fast edit distance.
## Example usage
See the docstrings for each function for further information.
```
(v1.3) pkg> add Edlib
[...]julia> using BenchmarkTools, Edlib
help?> Edlib
search: Edlib readlink readline readlinesJulia bindings for the edlib string alignment library (https://github.com/Martinsos/edlib).
See edit_distance, alignment_locations, alignment and align for computing alignment information.
Also see cigar for producing a cigar string from an alignment.
julia> @btime Edlib.edit_distance("missing", "mississippi")
1.230 μs (2 allocations: 116 bytes)
6julia> @btime Edlib.edit_distance("missing", "mississippi", mode=:infix)
1.310 μs (2 allocations: 124 bytes)
2julia> @btime Edlib.alignment_locations("missing", "mississippi", mode=:infix)
3.937 μs (8 allocations: 424 bytes)
(distance = 2, ranges = UnitRange{Int32}[1:5, 1:6, 1:7])julia> @btime Edlib.alignment("missing", "mississippi", mode=:infix)
6.000 μs (8 allocations: 448 bytes)
(distance = 2, range = 1:5, alignment = Edlib.Alignment[Edlib.MATCH, Edlib.MATCH, Edlib.MATCH, Edlib.MATCH, Edlib.MATCH, Edlib.INSERT_TARGET, Edlib.INSERT_TARGET], cigar = "5=2I")
```