From 912cc49dd87838e08606604ca034d06c40625d70 Mon Sep 17 00:00:00 2001 From: Simone Carlo Surace <51025924+simsurace@users.noreply.github.com> Date: Tue, 23 Jan 2024 21:21:06 +0100 Subject: [PATCH] Improve formatting Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- src/distances/sinus.jl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/distances/sinus.jl b/src/distances/sinus.jl index 1d2834c3c..706c1f5f8 100644 --- a/src/distances/sinus.jl +++ b/src/distances/sinus.jl @@ -24,4 +24,6 @@ end # Optimizations for scalar inputs (avoiding allocations) pairwise(d::Sinus, x::AbstractVector{<:Real}) = pairwise(d, x, x) -pairwise(d::Sinus, x::AbstractVector{<:Real}, y::AbstractVector{<:Real}) = abs2.(sinpi.(x .- y') ./ only(d.r)) +function pairwise(d::Sinus, x::AbstractVector{<:Real}, y::AbstractVector{<:Real}) + return abs2.(sinpi.(x .- y') ./ only(d.r)) +end