working till Image from R and labels from java