Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

activation intrinsics for neural networks #860

Draft
wants to merge 20 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
579 changes: 579 additions & 0 deletions doc/specs/stdlib_specialfunctions_activations.md

Large diffs are not rendered by default.

23 changes: 23 additions & 0 deletions include/common.fypp
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,29 @@ ${prefix + joinstr.join([line.strip() for line in txt.split("\n")]) + suffix}$
#:endif
#:enddef

#! Brace enclosed, comma separated Fortran expressions for a shape.
#!
#! It defines an output variable with the same shape as the input variable.
#!
#! Args:
#! varname (str): Name of the variable to be used as origin
#! origrank (int): Rank of the original variable
#!
#! Returns:
#! Shape expression enclosed in braces, so that it can be used as suffix to
#! define array shapes in declarations.
#!
#:def shape(varname, origrank)
#:assert origrank > 0
#:if origrank > 1
#:call join_lines(joinstr=", ", prefix="(", suffix=")")
#:for i in range(1, origrank+1)
size(${varname}$, ${i}$)
#:endfor
#:endcall
#:endif
#:enddef


#! Generates a routine name from a generic name, rank, type and kind
#!
Expand Down
3 changes: 2 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ set(fppFiles
stdlib_sorting_ord_sort.fypp
stdlib_sorting_sort.fypp
stdlib_sorting_sort_index.fypp
stdlib_specialfunctions_activations.fypp
stdlib_specialfunctions_gamma.fypp
stdlib_specialfunctions.fypp
stdlib_stats.fypp
stdlib_stats_corr.fypp
stdlib_stats_cov.fypp
Expand Down Expand Up @@ -114,7 +116,6 @@ set(SRC
stdlib_logger.f90
stdlib_sorting_radix_sort.f90
stdlib_system.F90
stdlib_specialfunctions.f90
stdlib_specialfunctions_legendre.f90
stdlib_quadrature_gauss.f90
stdlib_stringlist_type.f90
Expand Down
34 changes: 0 additions & 34 deletions src/stdlib_specialfunctions.f90

This file was deleted.

Loading
Loading