scalar and element wise op fixes