San Francisco and San Diego to clear thousands of previous marijuana convictions