Interpolating with scipy
Input : old_coordinates(list of coordinates len 60), old_temp (2d array of temperature shape 60*60), new coordinates(list of new coordinates len 60)
Output : new temp ?? (2d array of temp shape 60*60)
How can i plot it ?
What I tried:
combined_rotated_coordinates = list(zip(rotated_coordinates_x, rotated_coordinates_y))
combined_not_rotated_coordinates = list(zip(translated_coordinates_x, translated_coordinates_y))
combined_circle_coordinates = list(zip(x_coordinates_inside_circle,x_coordinates_inside_circle))
old_coords = np.array(combined_not_rotated_coordinates)
new_coords = np.array(combined_rotated_coordinates)
old_temps = ishape_temp_grid[1][:, :, 0].ravel() # Flatten the temperature array
# Perform interpolation
new_temps = griddata(old_coords, old_temps, new_coords, method='linear')
The error I got:
ValueError: different number of values and points