convert some observations into variables
Assume your table can be put into a pandas DataFrame object data with 4 columns as above. One way to achieve what you want is to do a GROUPBY using ID and Location. Then gradually assign values to each row of new table:

    newdata = pd.DataFrame(columns=['ID', 'Location', 'Feat1', 'Feat2', 'Feat3', 'Feat4', 'Feat5', 'Feat6'])
    grouped = data.groupby(['ID', 'Location'])

    for index, (group_name, d) in enumerate(grouped):
        newdata.loc[index, 'ID'] = group_name[0]
        newdata.loc[index, 'Location'] = group_name[1]
        for feature, amount in zip(d['Feature'], d['amount']):
            newdata.loc[index, feature] = amount