Skip to main content

Questions tagged [pytorch]

PyTorch is an open-source deep learning framework and API that creates a Dynamic Computational Graph, which allows you to flexibly change the way your neural network behaves on the fly and is capable of performing automatic backward differentiation.

pytorch
0 votes
1 answer
28 views

Simple DiffSharp example

How to convert this simple PyTorch snippet to DiffSharp? It's supposed to be similar but many functions are not to be found. # Define tensors with requires_grad=True to track computation history x = ...
Loco Barocco's user avatar
-4 votes
0 answers
26 views

PYTHON GIVING ERROR ON MODEL TRAINING ON GPU [duplicate]

I am trying to run a YOLO V8 model training on some images on GPU. After installing CUDA TOOLKIT and cuDNN matching versions with pytorch finally the code ran but giving some kind of error which I ...
Haseeb Khawaja's user avatar
1 vote
1 answer
24 views

--shm_size change for Docker in Nextflow pipeline: containerOptions not seeming to work

I am trying to increase the shared memory size for the Docker image being used to run a Nextflow pipeline. Per some indications online, I have added the following to my config file: docker { ...
ekofman's user avatar
  • 419
0 votes
0 answers
18 views

Cuda 121 - ERROR : Could not find a version that satisfies the requirement torch (from versions: none)

Trying to implement cuda 12.1 for some project, impossible to download torch, torchvision and torchaudio. Went to PyTorch.org but the command line (both from stable version and nightly version) e.g. ...
Maxence Mougin's user avatar
0 votes
0 answers
14 views

Runnig a simple model on PyTorch and Flask on NPU/GPU

My code is below: The code works when I run it on CPU however, when I move to a device such as NPU I get an error in the step when I try to move the tensor to the device tensor = tensor.to(device). ...
fanbondi's user avatar
  • 1,047
0 votes
0 answers
6 views

How to use an Iterable dataloader for training in pytorch

This is the code i use for creating my dataloaders: import torch import os import pickle import numpy as np from torch.utils.data import DataLoader, IterableDataset from datasets import Dataset, ...
Marina Thalassini's user avatar
0 votes
0 answers
12 views

Training LLM uses unexpected amount of GPU memory

I'm training model with self-implemented training loops. A 1.5B Qwen2 occupies 40G of GPU memory. When I did the same training using llama factory, it only takes about 24G. I tried to delete some ...
StaEx_G's user avatar
  • 13
0 votes
0 answers
8 views

Instance segmentation of very close objects of the same class

I have a project where I have to detect and segment a variable number of cross section layers of a given material. Each layer is right above or below of the other one and the bounding boxes overlap on ...
Kirill Meisser's user avatar
-3 votes
0 answers
28 views

Why the Intel Iris performs better than RTX 3050 laptop GPU in training a Yolov8 model [closed]

I have Dell G-15 Gaming laptop with Core i5 12500h and Rtx 3050. I am new to deep learning and AI. I am training a model with Yolo v8 for Automated Number Plate Detection with a custom dataset of 28k ...
Ahsan Irfan's user avatar
-2 votes
0 answers
38 views

More CPU cores lead to less performance in Deep Reinforcement Learning

We are working on a deep RL project and are encountering an issue where switching the training from our laptops to a workstation with more CPU cores causes the performance to drastically drop. An ...
Vince's user avatar
  • 7
0 votes
0 answers
12 views

Set torch.nn.Parameter's data, including the gradient

I have an existing nn.Parameter, and a tensor with a gradient. I want to set the tensor to the parameter in a way that the parameter will have the same gradient (including perhaps .grad_fn and so on). ...
Bipolo's user avatar
  • 73
0 votes
0 answers
17 views

Finetuning BERT on classification task, tensor device mismatch error

I'm having trouble on fine-tuning a BERT model on a classification task, as I'm quite new to this. My data is composed of two columns, "item_title" (my input) and "meta_categ_id" (...
Jerry Zhu's user avatar
0 votes
1 answer
19 views

When calling torchvision.transforms.Normalize and converting to PIL.Image, how are values above 1 handled?

Applying torchvision.Normalize should lead to values below 0 and above 1, and thus below 0 and 255 when switching to integer values. However, when watching the values, this seems NOT to be the case. ...
GabrielGodefroy's user avatar
0 votes
0 answers
15 views

Inconsistent tensor device management detected by autograd

In my code, I encountered issues with tensor device management, specifically with tensors stored in custom containers (TensorPack objects). Initially, tensors were defaulting to CPU, even when the ...
ir0098's user avatar
  • 149
1 vote
1 answer
60 views

Generate n random 2D points within a valid region

I want to generate a fixed number of random-uniformly distributed xy points within a valid mask. The generated points should be continuous, i.e. can be "between pixels". I'm looking for an ...
Toni's user avatar
  • 33

15 30 50 per page
1
2 3 4 5
1614