Questions tagged [machine-learning]
Implementation questions about machine learning algorithms. General questions about machine learning (concepts, theory, methodology, terminology, etc.) should be posted to their specific communities.
55,497
questions
0
votes
0
answers
7
views
Feature matrix and variable assignment
I am currently working on scikit module of ML in Python. I have a data set in .csv format. I have a problem in selecting feature matrix X and variable y. It says that the column headers which I input ...
0
votes
0
answers
8
views
Tensorflow: Failed to convert a NumPy array to a Tensor (Unsupported object type int)
I am receving error "ValueError: Failed to convert a NumPy array to a Tensor (Unsupported object type int)." on nn_model.fit line below.
Here my data.csv file contains columns: text (type ...
-3
votes
2
answers
40
views
Is self a keyword in python? [duplicate]
I Tried to answer but i have written something wrong.
I tried to answer but I written something wrong or may be I am doing something out of this question syllabus and i want a full descriptive type ...
-1
votes
0
answers
12
views
hyperspectral image classification using machine learning
Problem Statement: i have a dataset of hyperspectral images of human faces ,total participants are 42,Stress categories are 4-Baseline of emotional stress,emotional stress,Baseline of physical stress,...
0
votes
0
answers
6
views
Large .pkl data for backend is not pushed in github
I am learing ML. recently, I have made movie recomandation model from tmdb dataset, I processed data using that model in .pkl (binary) file. made backend using that data but, data is too large to push ...
-1
votes
0
answers
17
views
Tensorflow shape bug
I am doing deep Q learning and when I give my image to my model (from a selenium driver) everything is fine but when I try to fit my model it gives me this error
ValueError: Input 0 of layer "...
0
votes
0
answers
10
views
How can I retry FAIL trials in Optuna in a second run?
I am doing grid search with Optuna but FAIL trials are not repeated in a second run. Instead, already COMPLETE trials are uselessly repeated.
Here I describe the two problems separately:
when a trial ...
0
votes
1
answer
14
views
How to find how many different data are in a column of a data set in colab
I have a dataset consisting of approximately 400000 rows and 8 columns, and I just want to know how many different types of data are in one column, how can I do this? The data in a column is in the ...
-3
votes
0
answers
15
views
How to create a bot [closed]
I am curious to know that what is the code to make a bot like Alexa
I tried cloud computing but I am still in some doubt how the process was done. I am very much passionate towards Cloud computing and ...
-2
votes
0
answers
8
views
Cheap Cloud Computing Platform Needed for LLM Fine-Tuning and Inference [closed]
I am a recent AI graduate and I am now working for a very small startup company to explore (and try implement) where AI can be used in the company software. There isn't anyone else in the company that ...
-3
votes
0
answers
18
views
Machine learning forecast ideas [closed]
dummy data
I have to predict the story points for next 3 months for this data how can I start that ?
I 've to forecast story points for next 3 months which ML algorithm can I use
how to analyze the ...
0
votes
1
answer
25
views
YOLOv8 Custom Model Performance Issue with High-Resolution Dataset and Nvidia MX 150 GPU
I have recently developed a custom YOLOv8 model to detect glasses in my home environment. For this purpose, I created a dataset comprising 1000 images, captured using a Galaxy S22 Ultra camera at a ...
-1
votes
0
answers
10
views
Issue with implementing Attention mechanisms for Text Classification
I'm trying Attention mechanisms for the first time
I'm Unable to understand the use of Attention and MultiHeadAttention from keras. (Confusion in Implementation, Conceptually its clear)
Few of my ...
-4
votes
0
answers
14
views
What is a good roadmap/workflow for generating a headshot image using Python? [closed]
I want to create a Headshot Image using Python AI/ML so any one suggest me workflow how to create it and also suggest which Deep Learning/Machine Learning Model I use
I expect I upload simple five ...
0
votes
0
answers
14
views
"FileNotFoundError" During Text Recognition Inference using MMOCR in local device
SAR Text Recognition Model was used to custom train the license plates dataset to recognize the Nepali characters. I used Google Drive to train the model to recognize the texts. Now I want to use the ...
0
votes
0
answers
19
views
How to force train a model on GPU on Google Colab?
I'm trying to train a GAN model on Google Colab using Tensorflow. However, it takes a very very long time per epoch. I'm using Google Colab Pro Even though I chose T4 GPU as my runtime type T4 GPU ...
0
votes
0
answers
30
views
minMax TicTacToe code returning the wrong best possible move
Function "test(char[][] theBoard,char personWhoseTurnItIs)" is where the issue lies
In the output it says CPU won ignore that as the user actually won, don't even bother trying to fix that ...
0
votes
0
answers
19
views
spaCy Value Error: [E1041] Expected a string, Doc, or bytes as input, but got: <class 'float'>
I am trying to vectorize a Chinese-language input using spaCy.
My code is as follows:
nlp = spacy.load('zh_core_web_md')
def tokenize_and_vectorize_textZH(text):
clean_tokensZH = []
for ...
0
votes
0
answers
16
views
Is MLPClassifier Appropriate for Binary Classification?
I've written a program that uses MLPClassifier to solve a binary classification problem. It sort of works but I am not convinced this is the right model to use.
I have 1300 hextuples of integers to ...
0
votes
0
answers
7
views
How to predict %health percentage values for regression model
I am currently working on the a predictive maintenance dataset, that contains data from sensors, the occurrence of any errors and some characteristics of each machine. After feature engineering i have ...
0
votes
0
answers
11
views
problem in implementing FedAvg algorithm in TF
I am implementing FL using TF in google colab ( not using TFF), I am using Bot-IoT datasets and I divide the data into 10 clients such that each client take all types of classes so it can train on all ...
0
votes
0
answers
25
views
How do I run the following Python and Boto3 code?
I'm trying to explore machine learning models from AWS. AWS recently released a Bedrock service, and I would like to setup an environment to do that. I would also need to interact with S3, Langchain ...
-1
votes
0
answers
18
views
Best Machine-Learning Model for Binary Classification? [closed]
I have 1300 hextuples of integers to put into one of two classes: class 0 and class 1. A potential issue is that in my training data, 98% are in class 0 so I would get a 98% accuracy from a "...
-2
votes
0
answers
11
views
My ML model gives accuracy, F1 score, precision and recall as 1.0 but it seems overfitting [closed]
I have spotify Dataset of music.
playlist_genre is the target variable, It has 6 classes - rock, latin, r&b, rap, pop, instrumental
If I use label Encoding, to encode the target variable, then I ...
0
votes
0
answers
51
views
How can I fix my perceptron to recognize numbers?
My exercise is to train 10 perceptrons to recognize numbers (0 - 9). Each perceptron should learn a single digit. As training data, I've created 30 images (5x7 bmp). 3 variants per digit.
I've got a ...
-1
votes
0
answers
11
views
hyperspectral image classification using svm
import pandas as pd
import numpy as np
import os
from sklearn.impute import SimpleImputer
from sklearn.model_selection import train_test_split
from sklearn.ensemble import RandomForestClassifier
from ...
0
votes
0
answers
30
views
Issue with Agent Collecting 10 Products and Returning to Starting Point in a 12x11 Matrix
I have a 12x11 matrix. I want my agent to start from row 0, column 5 (reward points 1) and collect 10 products (reward points 100) and return to the starting point again. The problem is that once the ...
-4
votes
0
answers
17
views
Artificial Intelligence- Child AIs [closed]
Can an AI build another AI- child AIs?
Automated Machine Learning
Yes, an AI can be programmed to generate code or design another AI system. This process involves using techniques such as automated ...
0
votes
0
answers
14
views
ValueError: The two structures don't have the same nested structure. while loading a roberta model
I used the following roberta sentiment model to and fine tuned it to my text data.
roberta_model = TFAutoModelForSequenceClassification.from_pretrained('cardiffnlp/twitter-roberta-base-sentiment')
...
-2
votes
0
answers
19
views
ValueError: `decode_predictions` expects a batch of predictions (i.e. a 2D array of shape (samples, 1000)). Found array with shape: (None, 4) [closed]
When i pass decode_prediction it returned array shape
from keras.applications.vgg16 import preprocess_input,decode_predictions
predictions = vgg16model.predict(preprocessed_image)
decoded_predictions =...
0
votes
1
answer
22
views
Is there a way to save the pytorch model for environment without pytorch package?
We are training a model for a small minimal dependency software. The developer refused to include the PyTorch in their independence.
Is there a way to save the pytorch model in a way that they can ...
-4
votes
0
answers
23
views
Seeking Guidance on Comprehensive Vehicle Attribute Datasets for School Project [closed]
I'm working on a school project and in need of a comprehensive vehicle attribute dataset that includes information such as type, model, plate, color, make, and possibly images. I've searched various ...
-2
votes
0
answers
20
views
Confused about how a cost function is graphed [closed]
I am currently learning about gradient descent and I am confused as to how the cost function is graphed.
I understand the formula for the average sum of mean squared errors, but how are the individual ...
-4
votes
0
answers
60
views
What part of machine learning model training time takes actual matmul? [closed]
I'm learning PyTorch and want to understand all related stuff that goes under the hood when PyTorch trains neural network.
I wonder about two things:
where is computation graph stored while training? ...
-1
votes
0
answers
15
views
HuggingFace - "ModuleNotFoundError" for diffusers.UniPCMultistepScheduler
new to HuggingFace and ml/dl in general, so just wanted to try a model qr-code-monster found a script that I can use as an example so just got started with it in colab, I am stuck at ...
0
votes
1
answer
44
views
What error it is when I put gridsearchCV to multiclass svm model it work time almost day now from 1 minute?
When I run my multiclass svm model without gridsearchCV it use 1 minute I only have 3 class and 24 data per class. When I use put gridsearchCV to get more accuracy it work until now for day. I think ...
-2
votes
1
answer
26
views
Need advice on a loss function for a pytorch surrogate model [closed]
I was hoping to get advice on implementing a loss function for a surrogate model. I am working with micromechanical simulations of gas pores produced during processing in Additive Manufacturing, and ...
-1
votes
0
answers
15
views
how to create a model search using cell in nni?
How can I create a model search like the blocks of nasnet using cell https://nni.readthedocs.io/en/stable/reference/nas.html#
how can i add nn.cell in this model space
class MyModelSpace(ModelSpace):
...
-1
votes
0
answers
29
views
Getting An Error After Loading Up My ML Prediction Model [closed]
from flask import Flask, request, render_template
import pickle
import numpy as np
import os
app= Flask(__name__, template_folder="templates")
# Load the pickled model
model = pickle.load(...
-4
votes
0
answers
20
views
why AI booming rapidely now a days? [closed]
now a days we can see that everyone talking about the AI no one want to get a core knowledge of any topic just searching topic on AI tool and get the information what ever AI tools provides us ...
-3
votes
1
answer
47
views
Need help understanding the metrics being used in a research paper [closed]
I'm working on a machine learning model to reproduce the results of a paper using a very imbalanced dataset. In the paper, they state:
We measured performance using the AUC, PPV, and NPV as metrics ...
0
votes
0
answers
27
views
Using IVY framework i am getting-------ValueError: Classification metrics can't handle a mix of multiclass and multilabel-indicator targets
I am trying to implement a Ivy framework for modifying the model using the kdd
dataset
Here is the code
import ivy; ivy.set_backend("jax")
import jax; jax.config.update("jax_enable_x64&...
-2
votes
2
answers
35
views
Need python implementation for KNN regression with custom metric of gowers distance? [closed]
I have a sample data set and want to use gowers distance to find neigbors for KNN regression
Sample Input Data:
import pandas as pd
import numpy as np
df = pd.DataFrame([[1,2.6,'A'],[12,5,'X'],[4,7,'...
0
votes
0
answers
16
views
How to compute two-way partial dependence (ie, how to marginalize a model over multiple variables)?
I'd like to understand the computation of a 2-way partial dependence. In this case I'm working with a random forest. Toy model:
library(ggplot2) # access the mpg data set
mod <- ranger::ranger(...
0
votes
0
answers
15
views
how to train a single agent with two or more behaviors at the same time?
I am using unity ML agetns to train my agents, now i want to use two behaviors, one for navigation, another for decision making. I want the agent to train on these two behaviors simultaneously, i ...
-4
votes
0
answers
23
views
MACHINE LEARNING ALGORITHM TO DETECT ERRORS IN BIM MODELS [closed]
I'm working on an a school project. I am trying to develop a machine learning algorithm to detect errors in BIM models. For now I have narrowed down to bicycle shelters. I have quite a few Bim models ...
0
votes
0
answers
21
views
For splitting the data, does pytorch do it by itself randomly if I don’t specify split ratio?
For splitting the data, does pytorch do it by itself randomly if I don’t specify split ratio?
I am working on pytorch deep learning model autoencoder, i have dataset (csv file) with 10 classes and 500 ...
-1
votes
0
answers
17
views
InvalidArgumentError: Value for attr 'Tindices' of double is not in the list of allowed values: int16, int32, int64
I am trying to follow https://github.com/JingPoo/WSDM-kkbox_music_recommendation-with-KGE/tree/master and running https://github.com/JingPoo/WSDM-kkbox_music_recommendation-with-KGE/blob/master/...
0
votes
0
answers
21
views
XGBoost Classification, Different AUC score for XGBClassifier vs xgb.train Even After Rounding Prediction Probabilities
it seems that XGBClassifier is a wrapper over xgb.train. I was trying to train a binary classifier using xgb.train and "objective": "binary:logistic".
It seems that using xgb.train ...
0
votes
0
answers
13
views
How to convert object detection application in exe, by using openvino optimized model and YOLO
When I use this commend pyinstaller main.py --onefile -w to convert the project to exe file, I get this problem:
Error: [Errno 2] No such file or directory: ''C:\Users\sachin\Appdata\Local\Temp\...