pazuzzu / tuna-tune Goto Github PK
View Code? Open in Web Editor NEWCurated list of finetuning techniques and best practices
Curated list of finetuning techniques and best practices
I've nearly copy and pasted your code in medium. While running your code I consistently face error message below
RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.cuda.FloatTensor [3, 1, 178, 178]] is at version 16; expected version 14 instead. Hint: the backtrace further above shows the operation that failed to compute its gradient. The variable in question was changed in there or anywhere later. Good luck!
Traceback (most recent call last):
File "Lora and GPTQ.py", line 163, in <module>
trainer.train()
File "/home/jhkcool97/.local/lib/python3.8/site-packages/transformers/trainer.py", line 1561, in train
return inner_training_loop(
File "/home/jhkcool97/.local/lib/python3.8/site-packages/transformers/trainer.py", line 1895, in _inner_training_loop
tr_loss_step = self.training_step(model, inputs)
File "/home/jhkcool97/.local/lib/python3.8/site-packages/transformers/trainer.py", line 2830, in training_step
self.accelerator.backward(loss)
File "/home/jhkcool97/.local/lib/python3.8/site-packages/accelerate/accelerator.py", line 1964, in backward
self.scaler.scale(loss).backward(**kwargs)
File "/home/jhkcool97/.local/lib/python3.8/site-packages/torch/_tensor.py", line 522, in backward
torch.autograd.backward(
File "/home/jhkcool97/.local/lib/python3.8/site-packages/torch/autograd/__init__.py", line 266, in backward
Variable._execution_engine.run_backward( # Calls into the C++ engine to run the backward pass
File "/home/jhkcool97/.local/lib/python3.8/site-packages/torch/autograd/function.py", line 289, in apply
return user_fn(self, *args)
File "/home/jhkcool97/.local/lib/python3.8/site-packages/torch/utils/checkpoint.py", line 275, in backward
tensors = ctx.saved_tensors
RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.cuda.FloatTensor [3, 1, 178, 178]] is at version 16; expected version 14 instead. Hint: the backtrace further above shows the operation that failed to compute its gradient. The variable in question was changed in there or anywhere later. Good luck!
Could you let me know this error message in your code? Thanks in advance
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.