Belle II Software light-2601-hyperion
MyConcatenate Class Reference
Inheritance diagram for MyConcatenate:
Collaboration diagram for MyConcatenate:

Public Member Functions

 call (self, inputs)
 
 compute_mask (self, inputs, mask=None)
 
 get_config (self)
 

Detailed Description

Concatenate the 3D input tensors and their 2D masks along the axis=1 dimension.

Definition at line 15 of file model.py.

Member Function Documentation

◆ call()

call ( self,
inputs )
Expect the input to be list of 3D tensors

Definition at line 18 of file model.py.

18 def call(self, inputs):
19 '''
20 Expect the input to be list of 3D tensors
21 '''
22 return keras.ops.concatenate(inputs, axis=1)
23

◆ compute_mask()

compute_mask ( self,
inputs,
mask = None )
Expect the mask to be list of 2D mask tensors

Definition at line 24 of file model.py.

24 def compute_mask(self, inputs, mask=None):
25 '''
26 Expect the mask to be list of 2D mask tensors
27 '''
28 if mask is None:
29 return None
30 return keras.ops.concatenate(mask, axis=1)
31

◆ get_config()

get_config ( self)
Keras needs this

Definition at line 32 of file model.py.

32 def get_config(self):
33 '''
34 Keras needs this
35 '''
36 return super().get_config()
37
38

The documentation for this class was generated from the following file: