Some minor modifications in utils