Comments (5)
There are ways to load GPU weights to CPU only (changing device) with torch.load, have a look at:
https://discuss.pytorch.org/t/loading-weights-for-cpu-model-while-trained-on-gpu/1032
from superpoint_graph.
Hi,
first you need to set the option --cuda
to 0. But yes, the trained weights are only compatible with cuda, and you will need to retrain the model from scratch. It takes about 3 hours on my 1080. I haven't tried without CPUs, but it might take a while.
from superpoint_graph.
If i already have a model.pth.tar file, I don't need a GPU computer to semantically segment new test data correct? What is the correct command line arg to do that? Is this correct? Say I have a folder of new data to label in NewClouds
CUDA_VISIBLE_DEVICES=0 python learning/main.py --cuda 0 --dataset sema3d --SEMA3D_PATH $SEMA3D_DIR --db_test_name NewClouds --db_train_name train
--epochs -1 --lr_steps '[350, 400, 450]' --test_nth_epoch 100 --model_config 'gru_10,f_8' --ptn_nfeat_stn 11
--nworkers 2 --odir "results/sema3d/trainval_best" --resume
from superpoint_graph.
Hi,
sorry a bit late to the party, but the link sent by @bermanmaxim works.
the simplest way would be to add:
if not args.cuda:
model = model.cpu()
in the function resume
from superpoint_graph.
Hi, this should also work and allows you to load the model even if you have no cuda at all:
checkpoint = torch.load(args.resume, map_location=None if args.cuda else 'cpu')
from superpoint_graph.
Related Issues (20)
- Inconsistent class_maps for s3dis HOT 2
- CUDA error when training for Semantic3D HOT 1
- the version of metrics HOT 2
- When making ply_c, fatal error: numpy/ndarrayobject.h: No such file or directory HOT 3
- How to control the number of superpoints in a room? HOT 6
- Segmentation fault (core dumped) HOT 2
- Running on Stanford3dDataset_v1.2_Aligned_Version, the error occurs. HOT 6
- CMake error HOT 1
- Which version of Pytorch is needed for this code? HOT 1
- ModuleNotFoundError: No module named 'torchnet' HOT 3
- RuntimeError: scan failed to synchronize: an illegal memory access was encountered HOT 2
- L0-cut pursuit partition algorithm HOT 3
- cupy_backends.cuda.api.driver.CUDADriverError: CUDA_ERROR_ILLEGAL_ADDRESS: an illegal memory access was encountered HOT 3
- About the number of superpoints HOT 2
- Overfitting soon after around 30 epochs HOT 13
- How to visualize SSP HOT 1
- ValueError: need at least one array to concatenate HOT 1
- Pretrained weight link
- How to visualize SSP results? HOT 1
- What parts of the code should be changed in the custom dataset when using this network? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from superpoint_graph.