package Ġcom . github . j om of . k ane . impl . functions Ċ Ċ import Ġcom . github . j om of . k ane . Matrix Expr Ċ import Ġcom . github . j om of . k ane . Scalar Expr Ċ import Ġcom . github . j om of . k ane . impl .* Ċ Ċ private Ġval ĠCOUNT Ġby ĠSummary Op () Ċ Ċ class ĠCount Function Ġ: ĠAl gebra ic Summary Function Ġ{ ĊĠĠĠ Ġoverride Ġval Ġmeta Ġ= ĠCOUNT ĊĠĠĠ Ġoverride Ġfun Ġlookup Statistic ( statistic : ĠStreaming Samples ) Ġ= Ġstatistic . count . toDouble () ĊĠĠĠ Ġoverride Ġfun Ġreduce Arithmetic ( elements : ĠList < Scalar Expr >) Ġ= Ġconstant ( elements . size . toDouble ()) ĊĠĠĠ Ġoverride Ġfun Ġreduce Arithmetic ( value : ĠMatrix Expr ): ĠScalar Expr Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġconstant ( value . rows . toDouble () Ġ* Ġvalue . columns . toDouble ()) ĊĠĠĠ Ġ} Ċ } ĊĊ