def convert_embedding(builder, layer, input_names, output_names, keras_layer):
    """Convert a dense layer from keras to coreml.

    Parameters
    keras_layer: layer
    ----------
        A keras layer object.

    builder: NeuralNetworkBuilder
        A neural network builder object.
    """
    input_name, output_name = input_names[0], output_names[0]
    W = keras_layer.get_weights()[0].T
    builder.add_embedding(name=layer, W=W, b=None, input_dim=keras_layer.
        input_dim, output_channels=keras_layer.output_dim, has_bias=False,
        input_name=input_name, output_name=output_name)
