input: Write a function to implement a basic machine learning model in Python using logistic regression that performs binary classification on the given data. The function should train the model on the provided input data and output the model's accuracy score on the same data.
  
  
  assert machine_learning_model([[0.3, 0.2, 0.6], [0.3, 0.1, 0.4], [0.2, 0.3, 0.4], [0.7, 0.4, 0.2], [0.5, 0.2, 0.1]], [1, 0, 0, 1, 0]) == 1.0
  assert machine_learning_model([[0.1, 0.2, 0.3], [0.4, 0.5, 0.6], [0.7, 0.8, 0.9]], [0, 1, 0]) == 0.6666666666666666
  assert machine_learning_model([[0.2, 0.2, 0.2], [0.3, 0.3, 0.3], [0.4, 0.4, 0.4]], [1, 1, 1]) == 1.0
  assert machine_learning_model([[0.5, 0.5, 0.5], [0.6, 0.6, 0.6]], [0, 1]) == 0.5
  assert machine_learning_model([], []) == 0.0
  
output: 
  from sklearn.linear_model import LogisticRegression
  from sklearn.metrics import accuracy_score
  
  def machine_learning_model(X, y):
      if not X or not y:
          return 0.0
      model = LogisticRegression()
      model.fit(X, y)
      y_pred = model.predict(X)
      return accuracy_score(y, y_pred)
  