summaryrefslogtreecommitdiff
path: root/candle-nn/src/sequential.rs
diff options
context:
space:
mode:
authorLaurent Mazare <laurent.mazare@gmail.com>2023-10-20 16:28:50 +0100
committerGitHub <noreply@github.com>2023-10-20 16:28:50 +0100
commit7366aeac21d2be65bddf8691223f654c0ed8fd0b (patch)
tree9a79902b1944194d3c4105a87d41b50fc51ae15b /candle-nn/src/sequential.rs
parent99cf13e8e2f15b700c052ff8ec7b20f42badd96a (diff)
downloadcandle-7366aeac21d2be65bddf8691223f654c0ed8fd0b.tar.gz
candle-7366aeac21d2be65bddf8691223f654c0ed8fd0b.tar.bz2
candle-7366aeac21d2be65bddf8691223f654c0ed8fd0b.zip
Make func cloneable. (#1137)
Diffstat (limited to 'candle-nn/src/sequential.rs')
-rw-r--r--candle-nn/src/sequential.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/candle-nn/src/sequential.rs b/candle-nn/src/sequential.rs
index 2fef7742..bef99752 100644
--- a/candle-nn/src/sequential.rs
+++ b/candle-nn/src/sequential.rs
@@ -44,7 +44,7 @@ impl Sequential {
/// Appends a closure after all the current layers.
pub fn add_fn<F>(self, f: F) -> Self
where
- F: 'static + Fn(&Tensor) -> Result<Tensor> + Send,
+ F: 'static + Fn(&Tensor) -> Result<Tensor> + Send + Sync,
{
self.add(super::func(f))
}