<｜begin▁of▁sentence｜>### Instruction:
Given two 2x2 matrices represented as Matrix instances, can you use the __iadd__ magic method to perform in-place addition of the second matrix to the first one?
### Response:
import numpy as np

# Initialize two matrices using numpy arrays
class Matrix(object):
    def __init__(self, matrix):
        self.matrix = np.array(matrix)

    def __iadd__(self, other):
        if isinstance(other, Matrix):
            self.matrix += other.matrix
        elif isinstance(other, (int, float)):
            self.matrix += other
        return self

# Create instances of Matrix
matrix1 = Matrix([[1, 2], [3, 4]])
matrix2 = Matrix([[5, 6], [7, 8]])

# In-place add matrix2 to matrix1
matrix1 += matrix2

# Now matrix1 is the sum of matrix1 and matrix2
print('matrix1:', matrix1.matrix)
<|EOT|>
