human
Can you show me a Python function to change a dictionary to a numy array.
assistant
Here is a Python function to change a dictionary to a numy array

import numpy as np

def dict_to_array(dictionary):
        """
        Converts a dictionary to a numpy array.
        """
        return np.array([dictionary[key] for key in dictionary])

# Enter the dictionary
dictionary = {"a": 1, "b": 2, "c": 3}

# Calling the function
array = dict_to_array(dictionary)

# Printing the array
print(array)

#Example Output
# [1 2 3]

#Remember to inspect code for bugs.