export nn/scheduler DefaultSchedulerOptions()

This commit is contained in:
sugarme 2021-07-25 18:29:11 +10:00
parent bb00d244ed
commit dd03baa6b0
4 changed files with 11 additions and 4 deletions

View File

@ -10,6 +10,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Nofix]
- ctype `long` caused compiling error in MacOS as noted on [#44]. Not working on linux box.
## [0.4.3]
- Export nn/scheduler DefaultSchedulerOptions()
## [0.4.2]
- Added nn/scheduler NewLRScheduler()
- Added nn/conv config options

View File

@ -51,7 +51,7 @@ Gotch is in active development mode and may have API breaking changes. Feel free
```bash
wget https://raw.githubusercontent.com/sugarme/gotch/master/setup-gotch.sh
chmod +x setup-gotch.sh
export CUDA_VER=cpu && export GOTCH_VER=v0.4.2 && bash setup-gotch.sh
export CUDA_VER=cpu && export GOTCH_VER=v0.4.3 && bash setup-gotch.sh
```
### GPU
@ -89,9 +89,9 @@ Gotch is in active development mode and may have API breaking changes. Feel free
wget https://raw.githubusercontent.com/sugarme/gotch/master/setup-gotch.sh
chmod +x setup-gotch.sh
# CUDA 10.2
export CUDA_VER=10.2 && export GOTCH_VER=v0.4.2 && bash setup-gotch.sh
export CUDA_VER=10.2 && export GOTCH_VER=v0.4.3 && bash setup-gotch.sh
# CUDA 11.1
export CUDA_VER=11.1 && export GOTCH_VER=v0.4.2 && bash setup-gotch.sh
export CUDA_VER=11.1 && export GOTCH_VER=v0.4.3 && bash setup-gotch.sh
```
## Examples

View File

@ -22,6 +22,10 @@ func defaultSchedulerOptions() *SchedulerOptions {
}
}
func DefaultSchedulerOptions() *SchedulerOptions {
return defaultSchedulerOptions()
}
func WithLastEpoch(epoch int) SchedulerOption {
return func(o *SchedulerOptions) {
o.LastEpoch = epoch

View File

@ -1,6 +1,6 @@
#!/bin/bash
GOTCH_VERSION="${GOTCH_VER:-v0.4.2}"
GOTCH_VERSION="${GOTCH_VER:-v0.4.3}"
CUDA_VERSION="${CUDA_VER:-10.2}"
GOTCH_PATH="$GOPATH/pkg/mod/github.com/sugarme/gotch@$GOTCH_VERSION"