Comments (4)
Hi, would you provide a usecase about this feature? Why you need to stop training and then resume? Thanks
from tensorboardx.
I use tensorflow and pytorch both. In tensorflow, I can use tf.train.Supervisor to manange running models. The tf.train.supervisor can periodically save the running state (or check point) and summary on the disk. It can also restore the running state and the summary for the logging dir.
Use-case 1:Therefore, for some complicated models, I often divided the training process into multiple number of epochs. At end of each batch of epochs, I will check the training results to see whether the trained model is good. If it is Ok, I will terminate the training. If not, I will restart the training.
Use-case 2:For some case, electric power-off will terminate my training process. Thus, when I write a computer software, I often add the save_state and load_state in my program.
Because pytorch is simple and lack of framework like tf.train.supervisor, I need to write it by hand.
I hope these two use cases will help you.
Best
from tensorboardx.
I found that tensorboard concats data by default, if the event files are in the same directory.
with SummaryWriter('runs/Dec01_19-58-48_Z97X') as w:
for i in range(100):
w.add_scalar('test', np.random.randn(), i)
import time
time.sleep(1)
with SummaryWriter('runs/Dec01_19-58-48_Z97X') as w:
for i in range(100):
w.add_scalar('test', np.random.randn()+3, i+100)
As long as programmer knows the dir name (and global_iteration
), the second usecase can be fulfilled.
For case 1, do you mean something like rollback the history? (discard the bad training result) If I am correct, I guess that delete the event file manually do the trick.
from tensorboardx.
Got it. Today, I read the source code of tensorboard again. I found the same thing as you found.
Thanks a lot.
For case 1, I just want to pick some better results during the training. Maybe move the event file to another dir is ok.
from tensorboardx.
Related Issues (20)
- Test fail. HOT 3
- tensorboardX is incompatible with protobuf 4.21.0 HOT 16
- draw NaN with triangle
- Subsequent hparams missing HOT 4
- DeprecationWarning: crc32c.crc32 will be eventually removed, use crc32c.crc32c instead HOT 2
- AttributeError: 'NoneType' object has no attribute 'get_logdir' HOT 3
- Protobuf version HOT 4
- How can I connect previous log file into new one in tensorboard HOT 1
- How can i read tensorboard by python ? HOT 2
- Deprecation Warnings HOT 15
- OSS License compatibility question
- Remove upper pins on protobuf HOT 4
- tensorboardX is converting white/blank space and other non alphanumeric characters to underscore
- Update unittests for newer protobuf
- Possibility of v2.5.2 with upper pin on protobuf of <4? HOT 3
- The license_file parameter is deprecated HOT 3
- Loosening protobuf version limit breaking downstream packages HOT 7
- Is there an efficient way to log line plots? HOT 5
- EOFError multiprocessing HOT 1
- Set experiment name when using CometML HOT 1
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 tensorboardx.