What's the deal with Deno? We talk with a major contributor to find out. Listen now.

Questions tagged [python]

For questions related to AI implementation in the Python language

Filter by
Sorted by
Tagged with
0
votes
0answers
10 views

How to design the step() method in a custom-built environment when the action space is a 2-dimentional matrix?

I have an action space that is a matrix. I am struggling with finding how to choose how to take the action when the number of possible actions is huge.
0
votes
1answer
24 views

How to let the agent choose how to populate a state space matrix in RL (using python)

I have an agent (drone) that has to allocate subchannels for different types of User Equipment. I have represented the subchannel allocation with a 2-dimentional binary matrix, that is initialized to ...
0
votes
1answer
35 views

Can I train a neutral network to detect a fingerprint [closed]

I have been using tensorflow For neutral network
0
votes
0answers
11 views

How to include an iterative approach to obtain a super-resolution image?

Recently I am trying to implement super-resolution code to multiple low-resolution images. This is the code so far. So far I have used feature detecting and feature mapping to map multiple low-...
0
votes
0answers
25 views

How to implement or avoid masking for transformer?

When it comes to using Transformers for image captioning is there any reason to use masking? I currently have a resnet101 encoder and am trying to use the features as the input for a transformer model ...
1
vote
0answers
26 views

Pytorch Deep q network not learning and step not stepping towards target

I am trying to create a simple deep q network for rl with conv2d layers. I can’t figure out what I am doing wrong, and the only thing I can see that doesn’t seem right is when I get the model ...
0
votes
0answers
23 views

What framework for a project with a custom environment?

I'm planning an RL project and I have to decide which RL framework do I use if any at all. The project has a highly custom environment, and testing different algorithms will be required to obtain ...
1
vote
0answers
16 views

Layer dense expects 1 input(s), but it received 2 input tensors, how do I change that [migrated]

So I am a beginner, just approaching tensorflow2 and keras, I was just playing around and trying to make some models when i stumbled across the following error: ...
0
votes
0answers
21 views

Are there any python implementations of GGP games or how to use game logic written in GDL in python?

I'm writing a General Game Playing (GGP) AI in python. I'd like to test it on some GGP games. So are there any python implementations of GGP games? I found in http://games.ggp.org/base games written ...
1
vote
2answers
38 views

Extract features with CNN and pass as sequence to RNN

I read an article about captioning videos https://blog.coast.ai/five-video-classification-methods-implemented-in-keras-and-tensorflow-99cad29cc0b5 and I want to use solution number 4 (extract features ...
0
votes
1answer
25 views

A function in python that identifies the language a document is written in [duplicate]

How can I write a function in python that identifies the language a document is written in. For example I pass "Hello" as the parameter of the function and the function should return English
0
votes
2answers
36 views

How could I convolve a 4D image and a 4D filter with stride?

I want to create a CNN in Python, specifically, only with NumPy, if possible. For optimizing the time of convolution (actually correlation) in the network, I wanna try to use FFT-based convolution. ...
0
votes
0answers
17 views

Strategy to input and get large images in VGG neural networks

I'm using a transfert-style based deep learning approach that use VGG (neural network). The latter works well with images of small size (512x512pixels), however it provides distorted results when ...
0
votes
0answers
13 views

Is there a model suitable to predict one correct value based on a 2D input series?

I am using an encoder-decoder architecture, with 2 layers each in the encoder and decoder and 128 neurons in each hidden layer. The inputs are in a 2D form: one column has the days and the other ...
0
votes
1answer
30 views

Should image augmentation be applied before or after image resizing?

For the purposes of training a Convolutional Neural Network Classifier, should image augmentation be done before or after resizing the training images? To reduce file size and speed up training time, ...
1
vote
2answers
88 views

What are some programming-oriented resources for reinforcement learning?

I have been reading : Reinforcement Learning: An Introduction by Sutton and Barto. I admit it's a good read for learning RL whereas it's more theoretical with detailed algorithms. Now, I want ...
0
votes
0answers
9 views

drop_First=true during dummy variable creation in pandas [migrated]

I have months(Jan, Feb, Mar etc) data in my dataset and I am generating dummy variable using pandas library. pd.get_dummies(df['month'],drop_first=True) I want to understand whether I should use ...
0
votes
1answer
20 views

Wind speed forecasting using ARIMA model in Python3

Recently, I started working on time-series models and would mention that I am very new to python and ML as a whole. I tried to implement a time-series model on wind speed data. Being a newbie, I ...
0
votes
0answers
18 views

Should I move on from R and use Python for AI? [duplicate]

I have been using RStudio for a few years now, for various machine learning and deep learning techniques. For example, I want to build a trading bot that takes into account live news, which is tougher ...
1
vote
0answers
22 views

What are the best techniques to perform text simplification?

I'm evaluating the state of the art techniques to translate legal text to simple text, what are the best approaches for a non-English language (Portuguese)?
1
vote
1answer
34 views

What do the state features of KukaGymEnv represent?

I trying to use ddpg augmented with Hindsight Experience Replay (HER) on pybullet's KukaGymEnv. To formulate the feature vector for the goal state, I need to know what do the features of the state of ...
0
votes
0answers
20 views

Faster RCNN-RPN Network Training

I am trying to understand RPN network in Faster RCNN. I understand the concept of RPN network, Pass the input images to the pre trained CNN, and get the output as feature maps Make fixed size of the ...
1
vote
1answer
42 views

Implementing Gradient Descent Algorithm in Python, bit confused regarding equations

I'm following the guide as outlined at this link: http://neuralnetworksanddeeplearning.com/chap2.html For the purposes of this question, I've written a basic network 2 hidden layers, one with 2 ...
0
votes
0answers
12 views

Python code in LSTM to look at selective history

My dataset has 3 columns - a,b,c. Using b (and its history), I wish to predict c. Using list function and converting to array, I can tell python to look at last 20 b's for any b, as input to predict c....
1
vote
1answer
42 views

What is the Preferred Mathematical Representation for a Forward Pass in a Neural Network?

I know this may be a question of semantics but I always see different articles explain forward pass slightly different. e.g. Sometimes they represent a forward pass to a hidden layer in a standard ...
1
vote
1answer
47 views

DDPG doesn't converge for MountainCarContinuous-v0 gym environment

I am trying to implement Deep Deterministic policy gradient algorithm by referring to the paper Continuous Control using Deep Reinforcement Learning on the MountainCarContinuous-v0 gym environment. I ...
0
votes
1answer
22 views

Get Neural Network to predict a tag/class on a certain word using the surrounding words as context [PyTorch]?

I am somewhat a novice at the topic of Neural Netoworks and PyTorch. I am trying to create a model that takes a word (that I have modified very slightly) and a 'window' of context around it and ...
0
votes
0answers
12 views

Automated Scoring (non-english language) Using BERT

i'm a student and i'm new to NLP. I want to build an Automated Scoring system which is in Indonesian Language using BERT. The system is expected to be able to measure the similarity of an answer(e.g: ...
0
votes
2answers
47 views

Is there a neural network that accepts both the current input and previous output?

I am quite new to neural networks. I am trying to implement in Python a neural network having only one hidden layer with $N$ neurons and $1$ output layer. The point is that I am analyzing time series ...
1
vote
0answers
36 views

How to deal with very, very small time-series?

I have an ensemble of 231 time series, the largest among them being 14 lines long. The task at hand is to try to predict these time-series. But I'm finding this difficult due to the very small size of ...
2
votes
0answers
57 views

How can I find a specific word in an audio file?

I'm trying to train and use a neural network to detect a specific word in an audio file. The input of the neural network is an audio of 2-3 seconds duration, and the neural network must determine ...
0
votes
0answers
24 views

How to interpret the final neural network generated in NEAT-Python?

I made a simple obstacle collision game in Python and made a neural network which will play the game using the NEAT (NeuroEvolution of Augmenting Topologies) and I got a final network as follows -> ...
2
votes
1answer
57 views

How to predict the “word” based on the meaning in a document?

What I mean to say is For example, if I give the meaning of Apple from the dictionary as input to the program, it should give output as Apple. Or I say My day to day job involves monitoring and ...
0
votes
0answers
47 views

ConvNet - What to improve regarding architecture, procedure and technique?

I have a dataset of 180k images of license plates (so, not necessary to localize the license plate at first) for which I try to recognize the characters on the images (License plate recognition). All ...
0
votes
0answers
45 views

ALL OUTPUTS for my neural network return SAME as [0.0, 0.0, 0.0] all of time. Trying to make an AI that plays the Snake Game in Python using NEAT

I am trying to make an AI that plays the Snake Game using the NEAT library in Python. I have most things figured out. I have chosen 6 inputs for my neural network -> Is it clear in forward ...
0
votes
0answers
51 views

What are some scalable approaches to perform anomaly detection (for images with small cracks) with unsupervised learning?

I have some images with anomalies, like small cracks, but it's an imbalanced dataset. Please, suggest some effective scalable approaches. Should I consider convolutional auto-encoders? It's supposed ...
1
vote
0answers
45 views

Classification or regression for deep Q learning

DQN implemented at https://github.com/PacktPublishing/PyTorch-1.x-Reinforcement-Learning-Cookbook/blob/master/Chapter07/chapter7/dqn.py uses the mean square error loss function for the neural network ...
2
votes
0answers
128 views

Why is DDPG not learning and it does not converge?

I have used a different setting, but DDPG is not learning and it does not converge. I have used these codes 1,2, and 3 and I used different optimizers, activation functions, and learning rate but ...
0
votes
0answers
30 views

Problem fitting data using mlpregressor

I'm training a sklearn.neural_network.mlpregressor by a large data of students performance (an excel file with 740 students and 27 columns that are their qualities) and I want to predict their grades. ...
0
votes
0answers
42 views

How to calculate confidence score of OCR system?

I am working on an OCR project and I wonder how I can calculate the confidence score of my OCR system. I have digital multi meter images. There are some measurement results on the screens of devices ...
0
votes
0answers
37 views

Micro average f1_score, None average f1_score cannot increase more than 0.71, 0.50 respectively for the best model estimator

I am training a multilabel text neural network and the model metric I chose, to measure the performance of the training and the validation sets, is the f1 score (Micro average, None average). However, ...
0
votes
2answers
112 views

Practical skills in AI

For the past month I have been studying machine/deep learning, thus I have completed both the machine learning course and the deep learning specialization by Prof. Andrew Ng on coursera. In these ...
1
vote
1answer
42 views

Do correlations matter when building neural networks?

I am new to working with neural networks. However, I have built some linear regression models in the past. My question is, is it worth looking for features with a correlation to my target variable as ...
1
vote
1answer
56 views

Binary mode or Multi-label mode is correct when using binary crossentropy and sigmoid output function on multi-label classification

I would like to ask a question about the relationship of accuracy with the loss function. My experiment is a multiclass text classification problem, and I have built a Keras neural network to tackle ...
2
votes
0answers
38 views

Inaccurate masks with Mask-RCNN: Stairs effect and sudden stops

I've been using matterport's Mask R-CNN to train on a custom dataset. However, there seem to be some parameters that i failed to correctly define because on practically all of the images, the bottom ...
0
votes
0answers
23 views

How to feed the LSTM with different length for the latest time step?

I am having a training data set for a time-series dataset like below: ...
0
votes
1answer
38 views

Should I build an environment from scratch myself or it is not always needed?

I am inspired by the paper Neural Architecture Search with Reinforcement Learning to use reinforcement learning for optimizing a child network (learner). My meta-learner (controller or parent network) ...
2
votes
1answer
73 views

q learning appears to converge but does not always win against random tic tac toe player

q learning is defined as: Here is my implementation of q learning of the tic tac toe problem: ...
0
votes
1answer
56 views

How to make spacy lemmatization process fast?

I am applying spacy lemmatization on my dataset, but already 20-30 mins passed and the code is still running. Is there anyway to make it faster? Is there any option to do this process using GPU? My ...
1
vote
0answers
40 views

Why isn't my decision tree classifier able to solve the XOR problem properly?

I was trying to solve an XOR problem, and the dataset seems like the one in the image. I plotted the tree and got this result: As I understand, the tree should have depth 2 and four leaves. The ...

1
2 3 4 5 6