Questions tagged [python]

For questions related to AI implementation in the Python language

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

How can I initialize KerasTuner with a specific setting? [closed]

My situation is like this: I have started ten Keras-Tuner jobs in a machine 'A' that doesn't have a GPU and has a lesser number of CPU cores. These jobs are still running. How my P.I. tells me to ...
0
votes
0answers
38 views

Predicting height of a person using one image [closed]

I need help with trying to find why this algorithm is not working I am trying to predict the height of a person from a single picture this will be able to help us predict the height without multiple ...
2
votes
1answer
29 views

Feature Extraction for printer classification

I need some advice. I am currently trying to do a printer classification with ML/DL. What do I have? 11 colored-images with high resolution from 8 different inkjet-printers (in total 88 images) I have ...
2
votes
0answers
31 views

How rewards are playing role in Deep Q Network

I have started working on Reinforcement Learning, specifically DQN. And I have watched some interesting videos on it. However, I have some doubts about how the model works. Let's say we are playing ...
0
votes
0answers
19 views

Which AI algorithm to use for identifying API for a specific use from a list of APIs?

We have a legacy code solution in C#. We have to change the code so that it fetches internal data via APIs and not via DB calls. E.g. if the current code GETS Payment object from DB, we have to ...
-1
votes
0answers
33 views

Multi variate Polynomial Regression

I plotted a grpah of predicted vs actual results with the following code: ...
-1
votes
0answers
36 views

Alterntive Unsupervised Fake News Detection

I am trying to build a fake news detection system based on the Fake News Detection in Arabic Tweet, but I couldn't make as good accuracy scores as the research paper result. I guess that it is due to ...
1
vote
0answers
18 views

Adversarial Autoencoder is not working and not learning properly

I am trying to get an Adversarial AutoEncoder going using keras Fit method on a keras.model class but for some reason it is not working. Keep in mind that I tried updating encoder and decoder at the ...
0
votes
0answers
18 views

Find words in a raw text that are similar to a predefined array of words

I need a beginner advice regarding a simple application where I have a very limited set of topics in which i need to identify inside a user's natural language text/sentence. For example, one of the ...
-1
votes
1answer
32 views

How to take data at regular intervals? [closed]

The attached image is of a raw dataset from where I need the data of highlighted column after each interval of 10 rows. So, how can I write code for this?
2
votes
1answer
31 views

What is the best open source python repo for facial recognition? [closed]

I am looking for best open source python repo for facial recognition. Best if it uses tensorflow backend. I know you can train images to recognize. Yolo can be used if trained on face. To name the ...
1
vote
0answers
63 views

Implementation of MDP in python to determine when to take action clean

I am trying to model the following problem as a Markov decision process. In a steel melting shop of a steel plant, iron pipes are used. These pipes generate rust over time. Adding an anti-rusting ...
0
votes
0answers
15 views

What are the pros and cons of using a normal positional encoding in an adjacency matrix?

I understand that a normal positional encoding helps a transformer to understand pictures better and that it allows the (otherwise permutational invariant transformer-network) to create relationships ...
0
votes
0answers
8 views

Categorical Location based Time Series data Prediction using LSTMs

I have some time series data with ActivityType as location shared below. Each CaseID has 6 unique values with different ...
0
votes
0answers
26 views

Why isn't my perceptron having the expected costs?

I want to implement a single perceptron for linear regression using the following formulas: The input data for the first case is one column (x(392, 1); y(392, 1)) ...
2
votes
1answer
70 views

How to generate a response while considering past questions as well?

User: What is the tallest mountain? Agent: Everest User: Where is it located? # Agent hears: "Where is Everest located?" Agent: Nepal I want to be able ...
0
votes
1answer
32 views

Identify whether two companies are the same

I am trying to solve a problem where I need to map multiple variations of a company name to a single name. For example: say I have a company named ...
1
vote
0answers
35 views

How to parallelize multi-agent DDPG (MADDPG)

I am experimenting with MADDPG algorithm implemented in this repo. Since there were only a few agents (2-3) in the implementation (also in the original paper) steps like parameter updates, action ...
0
votes
1answer
77 views

Which of the following two implementations of a Least Squares classifier in Python is correct?

I am trying to solve a classification problem by implementing the Least Squares algorithm in Python. To solve this problem, I am implementing the linear algebra formula to train the classifier, which ...
1
vote
0answers
14 views

The results are not correct when predicting the future for a very long period of time with LSTM

I am currently using LSTM to try to predict future data in AirPassengers.csv. This is current code op my Colab (sorry for the comments are Japanese) https://colab.research.google.com/drive/...
0
votes
0answers
21 views

Which Neural Network Topology to choose, are Transformers suitable?

I have a regression problem and I am not quite sure which architecture to choose. I never worked with transformers before, but I generally understand how they work and I think they might be suitable. ...
0
votes
0answers
16 views

Graph neural network - what level (node or link or graph) prediction should be used for my problem?

I posted this on cross-validated but did not get a response. Trying my luck here. Sorry if this is not recommended. I have an undirected graph with nodes separated within a specified distance, say d, ...
0
votes
0answers
12 views

LSTM predictions are one time step lagging

My problem involves electricity prediction (time-series problem) for 1-hour ahead. I am using LSTM to forecast. Length of Dataset: 1 year at one-hour interval Input: Outdoor Temperature (Ot), ...
0
votes
1answer
21 views

Data analysis before feeding to ML pipeline

I'm new to machine learning and I've been working through a dataset of ~3000 records with ~100 features. I've been hand rolling Python and R scripts to analyse the data. For example, plotting the ...
0
votes
0answers
66 views

Compute IoU for each class in Mask R-cnn

I'm trying to compute the IoU, with the matterport Mask R-cnn implementation, for each class (13 in total) that i have in my dataset. For now i managed to compute the average IoU for all the classes ...
1
vote
0answers
40 views

Why doesn't this Monte Carlo Tree Search algorithm work properly?

PROBLEM I'm writing a Monte-Carlo tree search algorithm to play chess in Python. I replaced the simulation stage with a custom evaluation function. My code looks perfect but for some reason acts ...
0
votes
1answer
26 views

Train a deep learning model with input as a vector and predicts as a vector? [closed]

I am trying to build a Deep Learning model that takes a numeric vector $X$ of dimension $1 \times 50$ and predicts a numeric vector $y$ of dimension $1 \times 50$. It's a linear regression problem. I ...
0
votes
0answers
8 views

What next after LDA and NMF for topic modelling (with Python)?

I have used NMF and LDA for topic modelling in Python, with what I would call good results with NMF, and poor results with LDA. My data is highly domain-specific, with a lot of unique/specific ...
0
votes
0answers
12 views

when updating the bias matrix, do we get the total sum of dZ or the sum of the axis of dZ?

I'm currently studying how to implement a neural network from scratch to know how it works, I came across this article: https://www.samsonzhang.com/2020/11/24/understanding-the-math-behind-neural-...
0
votes
0answers
18 views

Multiple Entities, Multivariate, Multi-step - Time Series Prediction - Python

My goal is to create a time series model with Multiple Entities - I have multiple products with pre orders and they all have the a similar bell shaped curve peeking at the release date of the product ...
0
votes
1answer
50 views

Confusion about faster RCNN neither object nor background label

I am trying to construct a faster RCNN from scratch using KERAS. I am generating the tensor which contains whether anchor at each location corresponds to object or background or neither for training ...
0
votes
0answers
15 views

Using GAN to create multiple images as per multiple input layers

How to use GAN to create multiple images like https://opensea.io/collection/boredapeyachtclub here, each attribute is variable like fur, BG, Expression, Sunglasses, etc. Is there any GAN software to ...
1
vote
0answers
61 views

How do autoregressive attention mechanism work in multi-headed attention?

[LONG POST!!] I am working on a DNN model that works as an improviser to generate music sequences. The idea of generating music is based on taking a sequence of music nodes (their index representation)...
1
vote
2answers
48 views

Best way to use/learn ML for board-game reinforcement learning

I am relatively new to Python but I taught myself enough to code a two-player board game that is similar to chess. It has a simple Tkinter UI. Now I am dipping into machine learning, and I want to ...
0
votes
0answers
19 views

How to improve Face matching time

I'm working on a project that aims to detect each person's face while entering to a public space and store entering time and the person's image (array format) in Elasticsearch, and then detect each ...
1
vote
0answers
29 views

How do I select the number of neurons for each layer in an auto-encoder for dimensionality reduction?

I am trying to apply an auto-encoder for dimensionality reduction. I wonder how it will be applied on a large dataset. I have tried this code below. I have total of 8 features in my data and I want to ...
-1
votes
1answer
28 views

error while fitting auto encoder for anomaly detection on sensor data [closed]

I have sensor data like this and it's unsupervised and it has almost 800 features. my use-case is for anomaly detection. I applied Principal component analysis (PCA) for dimensionality reduction. now ...
1
vote
0answers
13 views

ML model to predict values from text (a lot of training training data)

I have around 1M entries of the type: id | big5_openness | big5_conscientiousness | big5_extraversion | big5_agreeableness | big5_neuroticism | input_text Where <...
1
vote
0answers
291 views

If I have a feature matrix of shape $1200 \times 2000$, should I have $2000$ input neurons?

I have an input feature matrix (row-normalized) of size $1200 \times 2000$. When I am writing my neural network, is the number of input neurons equal to the number of columns, that is $2000$? Is it ...
0
votes
1answer
48 views

How to retrain Facenet model?

I want to calculate the similarity or distance of two faces, and I'm using python. I have read and do what this tutorial says. but the result is not good (the similarity of same faces and similarity ...
2
votes
2answers
66 views

Minimum video quality for facial recognition

I am currently working on a small project where I am trying to automate some stuff at home. I am building a model capable of identifying my face with OpenCV. This will be a live feed. I am making the ...
0
votes
0answers
7 views

How can we use Deep Learning for Faults Tolerence in Distributed System?

Cloud Computing is the best example of Distributed Systems. The devices or nodes used in Distributed Systems consume and produce Big Datas, Hence there are chances of fault occurence from any end ...
1
vote
2answers
64 views

What would be the reason behind using plots (such as box-plots or histograms) for ML development?

I've been learning Python machine-learning using this project report and the guy who wrote it begins by visualizing his data using various statistical analysis methods: histograms, density plots, box ...
2
votes
0answers
34 views

Is there a technique for analyzing the relationship between time-series clusters?

I have two time-series datasets (temperature and speed of the vehicle). I will use Agglomerative Hierarchical Clustering and DTW to cluster both datasets. I am looking for a technique (like regression ...
0
votes
0answers
17 views

Understanding metrics, understanding my LSTM results

I'm trying to learn about forecasting time-series methods, my first approach to achieve it is using LSTM. Lets suppose I have my data well processed, and I have my data time-series correctly. In that ...
0
votes
0answers
105 views

Why does KNN algorithm perform better on Word2Vec than on TF-IDF vector representation?

I am doing a project on multi-class text classification and could do with some advice. I have a dataset of reviews that are classified into 7 product categories. Firstly, I create a term-document ...
0
votes
0answers
9 views

Preprocessing deterministic data with sklearn

I am trying to create a set of ML models that will serve as a replacement for a complex deterministic simulation. The simulation requires 4 inputs (x1, x2, x3 and x4) to determine 4 different outputs (...
0
votes
1answer
49 views

Exploration for softmax should be binary or continuous softmax?

Maybe it's silly to ask but for random exploration in an RL for choosing discrete action, that in the neural network last layer softmax will be used, what random samples should we provide? binary like ...
0
votes
0answers
21 views

Can I use binary numbers and plain floats in the same neural network input for reinforcement learning?

I'm modeling a system whose configuration can be represented by a binary array ([1,0,0,1] or [0,1,0,0], for example), and the agent can move on a 2D space (thus having 3 DOF), and the action the agent ...
1
vote
0answers
34 views

Is a true RNN auto encoder possible with Keras/TF

I want to get some encodings for temporal data (with a highly varying number of timesteps). The dataset is of the format: ...

1
2 3 4 5
7