Added empty and pinned sparse, determine_sparsity.