Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Apr 08 14:20
    AlexDBlack closed #8828
  • Apr 08 11:46
    CyrusDobbs commented #8827
  • Apr 08 11:46
    CyrusDobbs commented #8827
  • Apr 08 10:42
    AlexDBlack labeled #8832
  • Apr 08 10:33
    atuzhykov edited #8832
  • Apr 08 10:29
    atuzhykov edited #8832
  • Apr 08 10:28
    atuzhykov opened #8832
  • Apr 08 09:54
    raver119 commented #8831
  • Apr 08 09:52
    CyrusDobbs commented #8827
  • Apr 08 09:49
    AlexDBlack commented #8831
  • Apr 08 09:43
    raver119 assigned #8797
  • Apr 08 09:43
    raver119 assigned #8797
  • Apr 08 09:43
    raver119 unassigned #8797
  • Apr 08 09:35
    saudet commented #8831
  • Apr 08 09:14
    treo commented #8827
  • Apr 08 08:58
    treo closed #8829
  • Apr 08 08:58
    treo commented #8829
  • Apr 08 08:51
    raver119 assigned #8831
  • Apr 08 08:43
    AlexDBlack closed #8830
  • Apr 08 08:43
    AlexDBlack commented #8830
Tobi
@tobq
Anyyonee know how to get the Open Ai Gym working in java, using the deeplearning4j repo
Raul Feresteanu
@rferesteanu
I figured it out. To anyone stumbling across this in the future, you have to get the shape of the output INDArray from the calculateOutputShape method on the DynamicCustomOp
Tobi
@tobq

@SidneyLann Should I just be able to import org.bytedeco:gym-platform then as a maven dependency?

https://github.com/bytedeco/javacpp-presets/tree/master/gym

Tobi
@tobq
I'm confused
f
@SidneyLann
should be
Justas
@RustiGear_twitter
To impute data entries that are missing should i use conditionalReplaceValueTransform on TransformProcess.Builder that check for null ?
zaners123
@zaners123
Many of the tutorials such as the EMNIST and MNIST call functions that can't download the datasets because the hosts don't exist anymore (such as "blob.deeplearning4j.org" and "benchmark.deeplearn.online"). Is there any way around this?
zaners123
@zaners123
ope actually nevermind, if you manually put the files in the ~/.deeplearning4j/data/ folder, you can do the MNIST (and likely EMNIST) tutorials
oen9
@oen9
Hi, is it possible to somehow download http://blob.deeplearning4j.org/datasets/aisdk_20171001.csv.zip from tutorial?
ivan4github
@ivan4github
BERT in deeplearning4j: Looks like deeplearning4j is welcoming BERT, but could only find bits and pieces and nothing in dl4j-examples-beta6. Where could I find a starting point to use BERT as synonyms finder, something close to Word2vec nearest ?
fortuneNext
@fortuneNext
StackTrace.PNG
I want to import a Keras (2.3.1) model using KerasModelImport.importKerasSequentialModelAndWeights("path.h5") but im getting a NullPointerException.
Someone knows what could be the reason for that? Using BETA6.
fortuneNext
@fortuneNext
(Model was created as here: https://www.youtube.com/watch?v=wQ8BIBpya2k )
Bartosz Kruba
@bartoszkruba
Hi! I'm trying to create NeuralNetConfiguration with dl4j-beta6. There seems to be no option for configuring learningRate backpropagation and pretrain. Were those settings removed in newer versions or am i doing something wrong?
Paul Childs
@DPCII
I'd like to verify that models do not uptrain automatically using, for example, vec.writeParagraphVectors(vectorsFile.pv)
This will just overwrite the current .pv file, right?
j1234d2003
@j1234d2003

I have a Keras 2.3.1 h5 CNN fully trained model that I import using DL4J 1.0.0-beta6 version. I intend to use DL4J for evaluating outputs for specific input images. Currently Keras prediction outputs don't match DL4J outputs. The shapes of the inputs are different Keras input shape is (4, 150, 150, 3) whereas DL4J
input shape is [4, 3, 150, 150]. I could not find any sample DL4J code which
performs predictions on a CNN (or any network) trained model imported from
Keras that use images for predictions in Java and hence cannot ascertain if this
is an issue.

Questions:
1) What is the right shape of input required ini DL4J for the imported Keras
Model that expects image input.

2) If input shapes have to match between DL4J and Keras, I cannot identify a
way to build a "channel last" INDArray from a set of input images.

3) I need to also perform this on Keras imported mixed multi-input and
multi-output networks. What is recommended way to feed inputs to such networks
for predictions.

CURRENT CODE SNIPPET:

Keras:
...

# Build and train the CNN Model
...
imgGenerator = ImageDataGenerator(rescale=1./255)
testDir = "/test"

testData = np.array([["cat.1500.jpg"],["cat.1501.jpg"],["dog.1500.jpg"],["dog.1501.jpg"]])
testDf = pd.DataFrame(testData, columns=["file"])
netInput=imgGenerator.flow_from_dataframe( dataframe=testDf, 
    directory=testDir, x_col="file", y_col=None, 
    batch_size=testData.shape[0], seed=42, shuffle=False, class_mode=None, 
    target_size=(150, 150))
netOutput = model.predict(netInput);
print("Prediction: ", netOutput)

model.save("sample.h5");

Result:
Prediction: [[0.01729406]
[0.76219445]
[0.40130898]
[0.9373665 ]]

Shape of the batch generated by netInput is (4, 150, 150, 3)

DL4J:

String[] testImgs = new String[]{"cat.1500.jpg","cat.1501.jpg","dog.1500.jpg","dog.1501.jpg"};

INDArray[] ret = new INDArray[testImgs.length];
int count = 0;
for (String testImg: testImgs)
{
    File f = new File(mInputPath + "/test", testImg);
    NativeImageLoader loader = new NativeImageLoader(150, 150, 3);
    INDArray image = loader.asMatrix(f);
    DataNormalization scalar = new ImagePreProcessingScaler(0, 1);
    scalar.transform(image);
    ret[count] = image;
    count++;
}
// Concatenate the array along dimension 0.
INDArray netInput = Nd4j.concat(0, ret);
INDArray netOutput = model.output(netInput);
System.out.println("Prediction: ", netOutput)

Result:
Prediction: [[0.0381],
[0.7351],
[0.5337],
[0.8388]]

Shape of netInput is [4, 3, 150, 150]

Ali Akhtar
@AliAkhtar__twitter
Which maven dependencies do I need to include in order to be able to use the Word2Vector functionality i.e https://deeplearning4j.org/docs/latest/deeplearning4j-nlp-word2vec ?
On https://github.com/eclipse/deeplearning4j-examples/blob/master/pom.xml I'm not seeing any dependencies but I am seeing a lot of plugins etc, are these plugins necessary for using Word2Vec?
dagf2101
@dagf2101
Hi, I'm trying to predict some variables (angle and distance) from different input variables and data. Of I understand correctly this is a multi target regression problem, am I right ? For the implementation should I start with the regression examples and simply add 2 values output instead of a single value output ? Thx ?
Bastien Enjalbert
@bastienjalbert
@AlexDBlack Don't want to reopen this github issue : deeplearning4j/DataVec#516 but what is the current proposal status ? Did it get implemented ?
Ali Akhtar
@AliAkhtar__twitter
Which maven dependency should I import in order to be able to access org.deeplearning4j.models.embeddings.loader.WordVectorSerializer ?
Ali Akhtar
@AliAkhtar__twitter
oh, its deeplearning4j-nlp
o.n.l.a.o.e.DefaultOpExecutioner - Backend used: [CPU]; OS: [Linux]
How can I get this to use my GPU?
conquer66666
@conquer66666
hi ,where to find out the import org.deeplearning4j.examples.download.DownloaderUtility in the example code?
conquer66666
@conquer66666
I cannot find this class
conquer66666
@conquer66666
I find it under the shared-utilities
thomas-trendsoft
@thomas-trendsoft
i try get an iterator for some rnn computation graph the csv needs to be split in to vectors like: .addInput("myReader",0,2).addInput("myReader",3,8) from RecordReaderMultiDataSetIterator is there anything like this on the class: SequenceRecordReaderDataSetIterator
Raul Feresteanu
@rferesteanu
How do I get the row and column indices out of INDArray.argMax for a 2D array?
Barney Stinson
@Barney_Stinson_gitlab
any c# programmer here...?
Daniel MÃ¥rtensson
@DanielMartensson
@Barney_Stinson_gitlab Only Java ;)
Raul Feresteanu
@rferesteanu
From what I understand argMax/argMin seems to return indices along rows/columns but I'd like to know if I can get it to return the row and column indices of the element in question
Raul Feresteanu
@rferesteanu
Nevermind, I wrote my own helper. Would still be a nice addition to the API
tintinxue1
@tintinxue1
@fortuneNext try Nd4j.setDefaultDataTypes(DataType.DOUBLE,DataType.DOUBLE); put this at the begining of main
tintinxue1
@tintinxue1
I have a question, i tried to import a keras model. the keras model has masking layer plus lstm(64) and dense layers. taking input the padded sequence of one-hot encoded vectors. After importing, i can see it's maskzerolayer then lstm dense layer. Checked each layer weights, the lstm layer weights don't match up, all others match up with python version. The LSTM in dl4j has timestep and features in a swap position compared to python version. The input has been modified accordingly. But it just won't give same result with python verion, any help please?
conquer66666
@conquer66666
I run the example code of UIExample,when i go to http://localhost:9000/train, it shows Resource not found,and i search the project ,only two files(log4j ,logback configure file) under the resource folder,where are the needed resource ?
conquer66666
@conquer66666
lemair
@lemair
Hi, I'm trying to build regression but have next Exception https://gist.github.com/lemair/2e44f16a3b232019dbf3983db42a22ac
Ilya
@Eljah
Hello! I'm trying to play around https://github.com/wmeddie/dl4j-gans and to add UIServer server there to observe metrics of the GAN network. But still getting troubles,. First, I got the missing class exceptin, after updating to beta6 I just don't see any localhost:9000 starts for the UI Server, while the calculation is going forward fine
and the second question is how it is designed to use only part of the large jpeg image (2000x3000, 3 chanels) while I instantiate the ImageRecordReader(100, 100, 1). Not clear should I prepare the image by myself in order to use imageRecorderReader correctly: https://stackoverflow.com/questions/60198054/correct-initialization-of-imagerecordreaderlong-height-long-width-long-channe
MOKHEE LEE
@spaceking7_twitter
Hi! I am dl4j begginer, I have a question about scope . Is there some dl4j example for scope of data ?
For example, I teach the A.I below data.
"from 1 to 10 =>legend 1, from 11 to 20 => legend 2, from 21 to 30 => legend 3, from 31 to 40 => legend 4, ... "
Then I can give the scope (a legend) him if a customer input a data.
I am sorry My English is not perfect. I hope you understand it that i want to do.
Dineshdinu16
@Dineshdinu16
Hi,
I have been using computation graph with LSTM layers. But the dependency jars of these have been around 35 jars for linux which sums up to 125 MB. Is there any way to reduce the size by removing the unwanted files from the jar? Most of the jar size where occupied by ".so" files.
AmirLand
@AmirLand6_twitter
Hi, I hope you are all well. I followed the quick start instruction. however, I got an error that the shared utility dependency couldn't resolve. is there any help or recommendation?
MOKHEE LEE
@spaceking7_twitter
if you use eclipse , then you have to import "shared-utilities" project also in your eclipse Package Explorer. I fixed by it.
deeplearning4j-examples-master/shared-utilities
MOKHEE LEE
@spaceking7_twitter
or you can refer "eclipse/deeplearning4j#8307"
git clone https://github.com/eclipse/deeplearning4j-examples
cd shared-utilities
mvn install
cd ../dl4j-examples
mvn install