Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 5a9d3f64 authored by hhakim's avatar hhakim
Browse files

Add a warning in matfaust.rand raised when a user tries to create a complex...

Add a warning in matfaust.rand raised when a user tries to create a complex Faust in single precision (not yet supported, cf. #223).
parent 3cc14b1e
Branches
Tags
No related merge requests found
...@@ -222,6 +222,9 @@ function F = rand(M, N, varargin) ...@@ -222,6 +222,9 @@ function F = rand(M, N, varargin)
error('field has an unknown char array value.') error('field has an unknown char array value.')
end end
e = MException('FAUST:OOM', 'Out of Memory'); e = MException('FAUST:OOM', 'Out of Memory');
if(field == COMPLEX && strcmp(dtype, 'float'))
warning('Complex Faust-s are not available in single precision (only double precision is possible).')
end
if(strcmp(dev, 'cpu')) if(strcmp(dev, 'cpu'))
if(field == COMPLEX) if(field == COMPLEX)
core_obj = mexFaustCplx('rand', num_rows, num_cols, fac_type, min_num_factors, max_num_factors, min_dim_size, max_dim_size, density, per_row); core_obj = mexFaustCplx('rand', num_rows, num_cols, fac_type, min_num_factors, max_num_factors, min_dim_size, max_dim_size, density, per_row);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment