Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pypocketfft
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
4
Issues
4
List
Boards
Labels
Service Desk
Milestones
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Martin Reinecke
pypocketfft
Commits
1971f449
Commit
1971f449
authored
Aug 04, 2019
by
Peter Bell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove specific general_ functions {c, r, hartley & dcst}
parent
4ef6e3bf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
38 deletions
+12
-38
pocketfft_hdronly.h
pocketfft_hdronly.h
+12
-38
No files found.
pocketfft_hdronly.h
View file @
1971f449
...
...
@@ -2955,13 +2955,6 @@ struct ExecC2C
}
};
template
<
typename
T
>
void
general_c
(
const
cndarr
<
cmplx
<
T
>>
&
in
,
ndarr
<
cmplx
<
T
>>
&
out
,
const
shape_t
&
axes
,
bool
forward
,
T
fct
,
size_t
nthreads
)
{
general_nd
<
pocketfft_c
<
T
>>
(
in
,
out
,
axes
,
fct
,
nthreads
,
ExecC2C
{
forward
});
}
template
<
typename
T
,
size_t
vlen
>
void
copy_hartley
(
const
multi_iter
<
vlen
>
&
it
,
const
vtype_t
<
T
>
*
POCKETFFT_RESTRICT
src
,
ndarr
<
T
>
&
dst
)
{
...
...
@@ -3005,13 +2998,6 @@ struct ExecHartley
}
};
template
<
typename
T
>
POCKETFFT_NOINLINE
void
general_hartley
(
const
cndarr
<
T
>
&
in
,
ndarr
<
T
>
&
out
,
const
shape_t
&
axes
,
T
fct
,
size_t
nthreads
)
{
general_nd
<
pocketfft_r
<
T
>>
(
in
,
out
,
axes
,
fct
,
nthreads
,
ExecHartley
{});
}
struct
ExecDcst
{
bool
ortho
;
...
...
@@ -3028,13 +3014,6 @@ struct ExecDcst
}
};
template
<
typename
Trafo
,
typename
T
>
POCKETFFT_NOINLINE
void
general_dcst
(
const
cndarr
<
T
>
&
in
,
ndarr
<
T
>
&
out
,
const
shape_t
&
axes
,
T
fct
,
bool
ortho
,
int
type
,
bool
cosine
,
size_t
nthreads
)
{
general_nd
<
Trafo
>
(
in
,
out
,
axes
,
fct
,
nthreads
,
ExecDcst
{
ortho
,
type
,
cosine
});
}
template
<
typename
T
>
POCKETFFT_NOINLINE
void
general_r2c
(
const
cndarr
<
T
>
&
in
,
ndarr
<
cmplx
<
T
>>
&
out
,
size_t
axis
,
bool
forward
,
T
fct
,
size_t
POCKETFFT_NTHREADS
)
...
...
@@ -3172,14 +3151,6 @@ struct ExecR2R
}
};
template
<
typename
T
>
POCKETFFT_NOINLINE
void
general_r
(
const
cndarr
<
T
>
&
in
,
ndarr
<
T
>
&
out
,
const
shape_t
&
axes
,
bool
r2c
,
bool
forward
,
T
fct
,
size_t
nthreads
)
{
general_nd
<
pocketfft_r
<
T
>>
(
in
,
out
,
axes
,
fct
,
nthreads
,
ExecR2R
{
r2c
,
forward
});
}
#undef POCKETFFT_NTHREADS
template
<
typename
T
>
void
c2c
(
const
shape_t
&
shape
,
const
stride_t
&
stride_in
,
...
...
@@ -3191,7 +3162,7 @@ template<typename T> void c2c(const shape_t &shape, const stride_t &stride_in,
util
::
sanity_check
(
shape
,
stride_in
,
stride_out
,
data_in
==
data_out
,
axes
);
cndarr
<
cmplx
<
T
>>
ain
(
data_in
,
shape
,
stride_in
);
ndarr
<
cmplx
<
T
>>
aout
(
data_out
,
shape
,
stride_out
);
general_
c
(
ain
,
aout
,
axes
,
forward
,
fct
,
nthreads
);
general_
nd
<
pocketfft_c
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
ExecC2C
{
forward
}
);
}
template
<
typename
T
>
void
dct
(
const
shape_t
&
shape
,
...
...
@@ -3203,12 +3174,13 @@ template<typename T> void dct(const shape_t &shape,
util
::
sanity_check
(
shape
,
stride_in
,
stride_out
,
data_in
==
data_out
,
axes
);
cndarr
<
T
>
ain
(
data_in
,
shape
,
stride_in
);
ndarr
<
T
>
aout
(
data_out
,
shape
,
stride_out
);
const
ExecDcst
exec
{
ortho
,
type
,
true
};
if
(
type
==
1
)
general_
dcst
<
T_dct1
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
true
,
nthreads
);
general_
nd
<
T_dct1
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
else
if
(
type
==
4
)
general_
dcst
<
T_dcst4
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
true
,
nthreads
);
general_
nd
<
T_dcst4
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
else
general_
dcst
<
T_dcst23
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
true
,
nthreads
);
general_
nd
<
T_dcst23
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
}
template
<
typename
T
>
void
dst
(
const
shape_t
&
shape
,
...
...
@@ -3220,12 +3192,13 @@ template<typename T> void dst(const shape_t &shape,
util
::
sanity_check
(
shape
,
stride_in
,
stride_out
,
data_in
==
data_out
,
axes
);
cndarr
<
T
>
ain
(
data_in
,
shape
,
stride_in
);
ndarr
<
T
>
aout
(
data_out
,
shape
,
stride_out
);
const
ExecDcst
exec
{
ortho
,
type
,
false
};
if
(
type
==
1
)
general_
dcst
<
T_dst1
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
false
,
nthreads
);
general_
nd
<
T_dst1
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
else
if
(
type
==
4
)
general_
dcst
<
T_dcst4
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
false
,
nthreads
);
general_
nd
<
T_dcst4
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
else
general_
dcst
<
T_dcst23
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
ortho
,
type
,
false
,
nthreads
);
general_
nd
<
T_dcst23
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
exec
);
}
template
<
typename
T
>
void
r2c
(
const
shape_t
&
shape_in
,
...
...
@@ -3309,7 +3282,8 @@ template<typename T> void r2r_fftpack(const shape_t &shape,
util
::
sanity_check
(
shape
,
stride_in
,
stride_out
,
data_in
==
data_out
,
axes
);
cndarr
<
T
>
ain
(
data_in
,
shape
,
stride_in
);
ndarr
<
T
>
aout
(
data_out
,
shape
,
stride_out
);
general_r
(
ain
,
aout
,
axes
,
real2hermitian
,
forward
,
fct
,
nthreads
);
general_nd
<
pocketfft_r
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
ExecR2R
{
real2hermitian
,
forward
});
}
template
<
typename
T
>
void
r2r_separable_hartley
(
const
shape_t
&
shape
,
...
...
@@ -3320,7 +3294,7 @@ template<typename T> void r2r_separable_hartley(const shape_t &shape,
util
::
sanity_check
(
shape
,
stride_in
,
stride_out
,
data_in
==
data_out
,
axes
);
cndarr
<
T
>
ain
(
data_in
,
shape
,
stride_in
);
ndarr
<
T
>
aout
(
data_out
,
shape
,
stride_out
);
general_
hartley
(
ain
,
aout
,
axes
,
fct
,
nthreads
);
general_
nd
<
pocketfft_r
<
T
>>
(
ain
,
aout
,
axes
,
fct
,
nthreads
,
ExecHartley
{}
);
}
}
// namespace detail
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment