input: Write a function to perform stochastic gradient descent on the iris dataset in Python.
  assert perform_sgd(iris) > 0.8
  assert perform_sgd(iris, iterations=500, learning_rate=0.05) > 0.75
output: def perform_sgd(data, iterations=1000, learning_rate=0.01):
      import numpy as np
      from sklearn.preprocessing import StandardScaler
      from sklearn.model_selection import train_test_split
      from sklearn.datasets import load_iris
      from sklearn.metrics import accuracy_score
      from sklearn.utils import shuffle
  
      # Load the iris dataset
      iris = load_iris()
      X, y = iris.data, iris.target
      
      # Standardize features
      scaler = StandardScaler()
      X = scaler.fit_transform(X)
      
      # Only consider classes 0 and 1 for binary classification
      binary_mask = y < 2
      X, y = X[binary_mask], y[binary_mask]
      
      # Train-test split
      X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.3, random_state=42)
      
      # Initialize weights and bias
      weights = np.zeros(X_train.shape[1])
      bias = 0
      
      # Sigmoid function
      def sigmoid(z):
          return 1 / (1 + np.exp(-z))
      
      # Training using stochastic gradient descent
      for _ in range(iterations):
          X_train, y_train = shuffle(X_train, y_train)
          for i in range(X_train.shape[0]):
              xi = X_train[i]
              yi = y_train[i]
              linear_output = np.dot(xi, weights) + bias
              predicted = sigmoid(linear_output)
              
              # Compute gradients
              error = predicted - yi
              weights_gradient = xi * error
              bias_gradient = error
              
              # Update weights and bias
              weights -= learning_rate * weights_gradient
              bias -= learning_rate * bias_gradient
      
      # Prediction on test set
      linear_output_test = np.dot(X_test, weights) + bias
      y_pred = (sigmoid(linear_output_test) >= 0.5).astype(int)
      
      # Compute accuracy
      accuracy = accuracy_score(y_test, y_pred)
      
      return accuracy