Questions tagged [embedding]

An embedding is one instance of some structure contained within another instance, such as a group that is a subgroup.

An embedding is one instance of some structure contained within another instance, such as a group that is a subgroup.

Links:

1356 questions
7
votes
1 answer

My website loads slow because of too many embedded videos

My website loads slow because of too many embedded videos. I'm seen where there is an image (overtop of where the video is embedded) and you click it, at which point, the embedded video is loaded. Could anyone give me some help figuring out how to…
Cory
  • 109
  • 1
  • 2
  • 4
7
votes
1 answer

attempt to call global `print' (a nil value)

I have the following C file: //thing.c #include #include #include #include lua_State* L; int main(){ L = lua_open(); lua_dostring(L, "print(\"lua\")"); printf("hello\n"); …
ewok
  • 20,148
  • 51
  • 149
  • 254
6
votes
1 answer

Storing sentence embeddings in Google Cloud BigQuery

I am looking for a way to store embedding generated by language model like (T5), in BigQuery of Google. The embedding are in the form of Numpy array or tensor. I found 3 approaches: TFRecord, write it to a TFRecord file and store to cloud…
6
votes
2 answers

Recommended way to embed JVM in C program with NO library?

What's the recommended way to embed JVM in C program with NO library. This means JVM as a eDSL execution engine. (Not whole Java platform environment) I'm trying to use another JVM based language instead of Java itself.
eonil
  • 83,476
  • 81
  • 317
  • 516
6
votes
1 answer

Using BERT Embeddings in Keras Embedding layer

I want to use the BERT Word Vector Embeddings in the Embeddings layer of LSTM instead of the usual default embedding layer. Is there any way I can do it?
PeakyBlinder
  • 1,059
  • 1
  • 14
  • 35
6
votes
2 answers

How to use a pre-trained embedding matrix in tensorflow 2.0 RNN as initial weights in an embedding layer?

I'd like to use a pretrained GloVe embedding as the initial weights for an embedding layer in an RNN encoder/decoder. The code is in Tensorflow 2.0. Simply adding the embedding matrix as a weights = [embedding_matrix] parameter to the…
Jake
  • 61
  • 1
  • 4
6
votes
2 answers

Keras Layer Concatenation

I'm trying to see how I can create a model in Keras with multiple Embedding Layers and other inputs. Here's how my model is structured(E=Embedding Layer, [....]=Input Layer): E E [V V V] \ | / \ | / Dense | Dense Here is my code so…
Light
  • 375
  • 4
  • 11
6
votes
2 answers

Keras seq2seq - word embedding

I am working on a generative chatbot based on seq2seq in Keras. I used code from this site: https://machinelearningmastery.com/develop-encoder-decoder-model-sequence-sequence-prediction-keras/ My models looks like this: # define training…
6
votes
1 answer

Visibility of embedded private interfaces in Go

If I embed an interface with a lowercase name (private) into another interface with an uppercase name (public), I assume that code outside of the defining package cannot see the embedded private interface. Is this assumption correct? type b…
Ralph
  • 31,584
  • 38
  • 145
  • 282
6
votes
1 answer

Keras : How to use weights of a layer in loss function?

I am implementing a custom loss function in keras. The model is an autoencoder. The first layer is an Embedding layer, which embed an input of size (batch_size, sentence_length) into (batch_size, sentence_length, embedding_dimension). Then the model…
mat112
  • 71
  • 6
6
votes
3 answers

Embedding C++ Programs

I'm just getting into advanced C++ programming (object orientation), and I've been looking for hours on how to embed a C++ program into your average browser. I honestly have no idea how. I was thinking the same way you embed JavaScript with HTML…
Justin C.
  • 63
  • 1
  • 3
6
votes
1 answer

Keras: Embedding in LSTM

In a keras example on LSTM for modeling IMDB sequence data (https://github.com/fchollet/keras/blob/master/examples/imdb_lstm.py), there is an embedding layer before input into a LSTM layer: model.add(Embedding(max_features,128))…
jwm
  • 4,832
  • 10
  • 46
  • 78
6
votes
2 answers

Importing tensorflow when embedding python in c++ returns null

I've a question regarding embedding python into a C++ application. The setup is as follows: I have a large C++ application which generates some data (renders images in real-time) and displays them. I have also trained a neural network in python…
6
votes
1 answer

What files are required for Py_Initialize to run?

I am working on a simple piece of code that runs a Python function from a C/C++ application. In order to do this I set the PYTHONPATH and run initialize as follows: Py_SetPythonHome("../Python27"); Py_InitializeEx(0); Then I import my module and…
Matt McC
  • 63
  • 1
  • 1
  • 3
6
votes
1 answer

How to use tf.nn.embedding_lookup_sparse in TensorFlow?

We have tried using tf.nn.embedding_lookup and it works. But it needs dense input data and now we need tf.nn.embedding_lookup_sparse for sparse input. I have written the following code but get some errors. import tensorflow as tf import numpy as…
tobe
  • 1,671
  • 2
  • 23
  • 38