there is a problem when giving two input datasets.
will be complex debugging.