blas,graph,lapack: fix imports and code generation
MODIFY
blas/native/single_precision.bash
blas/native/single_precision.bash
@@ -11,7 +11,7 @@ WARNING='//\
# Level1 routines.
echo Generating level1single.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level1single.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level1single.go
cat level1double.go \
| gofmt -r 'blas.Float64Level1 -> blas.Float32Level1' \
\
@@ -28,12 +28,12 @@ cat level1double.go \
-e 's_^// D_// S_' \
-e "s_^\(func (Implementation) \)Id\(.*\)\$_$WARNING\1Is\2_" \
-e 's_^// Id_// Is_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
- -e 's_"math"_math "github.com/gonum/blas/native/internal/math32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
+ -e 's_"math"_math "gonum.org/v1/gonum/blas/native/internal/math32"_' \
>> level1single.go
echo Generating level1single_sdot.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level1single_sdot.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level1single_sdot.go
cat level1double_ddot.go \
| gofmt -r 'float64 -> float32' \
\
@@ -42,11 +42,11 @@ cat level1double_ddot.go \
\
| sed -e "s_^\(func (Implementation) \)D\(.*\)\$_$WARNING\1S\2_" \
-e 's_^// D_// S_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> level1single_sdot.go
echo Generating level1single_dsdot.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level1single_dsdot.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level1single_dsdot.go
cat level1double_ddot.go \
| gofmt -r '[]float64 -> []float32' \
\
@@ -55,11 +55,11 @@ cat level1double_ddot.go \
\
| sed -e "s_^\(func (Implementation) \)D\(.*\)\$_$WARNING\1Ds\2_" \
-e 's_^// D_// Ds_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> level1single_dsdot.go
echo Generating level1single_sdsdot.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level1single_sdsdot.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level1single_sdsdot.go
cat level1double_ddot.go \
| gofmt -r 'float64 -> float32' \
\
@@ -70,14 +70,14 @@ cat level1double_ddot.go \
-e 's_^// D\(.*\)$_// Sds\1 plus a constant_' \
-e 's_\\sum_alpha + \\sum_' \
-e 's/n int/n int, alpha float32/' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> level1single_sdsdot.go
# Level2 routines.
echo Generating level2single.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level2single.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level2single.go
cat level2double.go \
| gofmt -r 'blas.Float64Level2 -> blas.Float32Level2' \
\
@@ -94,14 +94,14 @@ cat level2double.go \
\
| sed -e "s_^\(func (Implementation) \)D\(.*\)\$_$WARNING\1S\2_" \
-e 's_^// D_// S_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> level2single.go
# Level3 routines.
echo Generating level3single.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > level3single.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > level3single.go
cat level3double.go \
| gofmt -r 'blas.Float64Level3 -> blas.Float32Level3' \
\
@@ -112,11 +112,11 @@ cat level3double.go \
\
| sed -e "s_^\(func (Implementation) \)D\(.*\)\$_$WARNING\1S\2_" \
-e 's_^// D_// S_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> level3single.go
echo Generating general_single.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > general_single.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > general_single.go
cat general_double.go \
| gofmt -r 'float64 -> float32' \
\
@@ -124,12 +124,12 @@ cat general_double.go \
| gofmt -r 'newGeneral64 -> newGeneral32' \
\
| sed -e 's/(g general64) print()/(g general32) print()/' \
- -e 's_"math"_math "github.com/gonum/blas/native/internal/math32"_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"math"_math "gonum.org/v1/gonum/blas/native/internal/math32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> general_single.go
echo Generating sgemm.go
-echo -e '// Code generated by "go generate github.com/gonum/blas/native"; DO NOT EDIT.\n' > sgemm.go
+echo -e '// Code generated by "go generate gonum.org/v1/gonum/blas/native"; DO NOT EDIT.\n' > sgemm.go
cat dgemm.go \
| gofmt -r 'float64 -> float32' \
| gofmt -r 'general64 -> general32' \
@@ -152,5 +152,5 @@ cat dgemm.go \
| sed -e "s_^\(func (Implementation) \)D\(.*\)\$_$WARNING\1S\2_" \
-e 's_^// D_// S_' \
-e 's_^// d_// s_' \
- -e 's_"github.com/gonum/internal/asm/f64"_"github.com/gonum/internal/asm/f32"_' \
+ -e 's_"gonum.org/v1/gonum/internal/asm/f64"_"gonum.org/v1/gonum/internal/asm/f32"_' \
>> sgemm.go

MODIFY
blas/testblas/benchautogen/autogen_bench_level1double.go
blas/testblas/benchautogen/autogen_bench_level1double.go
@@ -20,13 +20,13 @@ var copyrightnotice = []byte(`// Copyright 2014 The Gonum Authors. All rights re
// Use of this code is governed by a BSD-style
// license that can be found in the LICENSE file`)
-var autogen = []byte("// Code generated by \"go run github.com/gonum/blas/testblas/benchautogen/autogen_bench_level1double.go\"; DO NOT EDIT.\n")
+var autogen = []byte("// Code generated by \"go run gonum.org/v1/gonum/blas/testblas/benchautogen/autogen_bench_level1double.go\"; DO NOT EDIT.\n")
var imports = []byte(`import(
"math/rand"
"testing"
- "github.com/gonum/blas"
+ "gonum.org/v1/gonum/blas"
)`)
var randomSliceFunction = []byte(`func randomSlice(l, idx int) ([]float64) {
@@ -180,7 +180,7 @@ func init() {
}
func main() {
- blasPath := filepath.Join(gopath, "src", "github.com", "gonum", "blas")
+ blasPath := filepath.Join(gopath, "src", "gonum.org", "v1", "gonum", "blas")
pkgs := []struct{ name string }{{name: "native"}, {name: "cgo"}}
@@ -191,7 +191,7 @@ func main() {
os.Exit(1)
}
- err = exec.Command("go", "fmt", path.Join("github.com", "gonum", "blas", pkg.name)).Run()
+ err = exec.Command("go", "fmt", path.Join("gonum.org", "v1", "gonum", "blas", pkg.name)).Run()
if err != nil {
fmt.Println(err)
os.Exit(1)

MODIFY
graph/formats/dot/README.md
graph/formats/dot/README.md
The source code and any original content of the formats/dot directory is released under [Public Domain Dedication](https://creativecommons.org/publicdomain/zero/1.0/).
-The source code is also licensed under the gonum license, and users are free to choice the license which suits their needs.
+The source code is also licensed under the gonum license, and users are free to choose the license which suits their needs.
-Please see github.com/gonum/license for general license information, contributors, authors, etc on the Gonum suite of packages.
+Please see gonum.org/v1/gonum for general license information, contributors, authors, etc on the Gonum suite of packages.

MODIFY
graph/formats/dot/internal/dot.bnf
graph/formats/dot/internal/dot.bnf
@@ -154,8 +154,8 @@ _block_comment : '/' '*' { . | '*' } '*' '/' ;
// ### [ Syntax ] ##############################################################
<< import (
- "github.com/gonum/graph/formats/dot/ast"
- "github.com/gonum/graph/formats/dot/internal/astx"
+ "gonum.org/v1/gonum/graph/formats/dot/ast"
+ "gonum.org/v1/gonum/graph/formats/dot/internal/astx"
) >>
// === [ Files ] ===============================================================

MODIFY
graph/formats/dot/internal/lexer/lexer.go
graph/formats/dot/internal/lexer/lexer.go
@@ -17,7 +17,7 @@ import (
"io/ioutil"
"unicode/utf8"
- // "github.com/gonum/graph/formats/dot/internal/util"
+ // "gonum.org/v1/gonum/graph/formats/dot/internal/util"
"gonum.org/v1/gonum/graph/formats/dot/internal/token"
)

MODIFY
lapack/internal/testdata/dlahr2test/main.go
lapack/internal/testdata/dlahr2test/main.go
@@ -19,7 +19,7 @@ import (
"os"
"path/filepath"
- "github.com/gonum/lapack/internal/testdata/netlib"
+ "gonum.org/v1/gonum/lapack/internal/testdata/netlib"
)
type Dlahr2Test struct {

MODIFY
lapack/internal/testdata/dlaqr5test/main.go
lapack/internal/testdata/dlaqr5test/main.go
@@ -19,7 +19,7 @@ import (
"os"
"path/filepath"
- "github.com/gonum/lapack/internal/testdata/netlib"
+ "gonum.org/v1/gonum/lapack/internal/testdata/netlib"
)
type Dlaqr5Test struct {

blas,graph,lapack: fix imports and code generation