Skip to content

Commit

Permalink
remove_extra_newlines=true
Browse files Browse the repository at this point in the history
  • Loading branch information
anchal-physics committed Sep 20, 2023
1 parent 077d747 commit 0c7036c
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 13 deletions.
4 changes: 2 additions & 2 deletions .JuliaFormatter.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ long_to_short_function_def = true
margin = 88
normalize_line_endings = "unix"
pipe_to_function_call = true
remove_extra_newlines = false
remove_extra_newlines = true
separate_kwargs_with_semicolon = true
surround_whereop_typeparameters = true
trailing_comma = true
whitespace_in_kwargs = false
whitespace_ops_in_indices = false
whitespace_typedefs = true
yas_style_nesting = true
yas_style_nesting = true
7 changes: 0 additions & 7 deletions src/GGDUtils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,8 @@ export interp
export get_kdtree
export project_prop_on_subset!


include("recipes.jl")


function get_kdtree(space::OMAS.edge_profiles__grid_ggd___space)
grid_nodes = space.objects_per_dimension[1].object
grid_faces = space.objects_per_dimension[3].object
Expand All @@ -27,7 +25,6 @@ function get_kdtree(space::OMAS.edge_profiles__grid_ggd___space)
return KDTree(grid_centers; leafsize=10)
end


function interp(prop, kdtree::KDTree)
function get_interp_val(x::Number, y::Number)
nearest_indices, distances = knn(kdtree, Array([x, y]), 4)
Expand Down Expand Up @@ -56,12 +53,10 @@ function interp(prop, kdtree::KDTree)
return get_interp_val
end


function interp(prop, space::OMAS.edge_profiles__grid_ggd___space)
return interp(prop, get_kdtree(space))
end


"""
get_subset_centers(space::OMAS.edge_profiles__grid_ggd___space,
subset::OMAS.edge_profiles__grid_ggd___grid_subset)
Expand All @@ -79,7 +74,6 @@ function get_subset_centers(space::OMAS.edge_profiles__grid_ggd___space,
]
end


#! format: off
"""
project_prop_on_subset!(prop,
Expand Down Expand Up @@ -154,7 +148,6 @@ function project_prop_on_subset!(prop,
end
end


function project_prop_on_subset!(prop,
from_subset::OMAS.edge_profiles__grid_ggd___grid_subset,
to_subset::OMAS.edge_profiles__grid_ggd___grid_subset)
Expand Down
3 changes: 0 additions & 3 deletions src/recipes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
end
end


@recipe function f(
space::OMAS.edge_profiles__grid_ggd___space,
subset::OMAS.edge_profiles__grid_ggd___grid_subset,
Expand Down Expand Up @@ -94,7 +93,6 @@ end
end
end


@recipe function f(grid_ggd::OMAS.edge_profiles__grid_ggd, prop::OMAS.IDSvectorElement)
subset = get_grid_subset_with_index(grid_ggd, prop.grid_subset_index)
space = grid_ggd.space[subset.element[1].object[1].space]
Expand Down Expand Up @@ -156,7 +154,6 @@ end
end
end


@recipe function f(
grid_ggd_arr::Vector{OMAS.edge_profiles__grid_ggd},
prop::OMAS.IDSvectorElement,
Expand Down
1 change: 0 additions & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ function test_interp()
return true
end


function test_project_prop_on_subset()
b2gmtry = "$(@__DIR__)/../samples/b2fgmtry"
b2output = "$(@__DIR__)/../samples/b2time_red.nc"
Expand Down

0 comments on commit 0c7036c

Please sign in to comment.