Skip to content

Commit

Permalink
pfam proper count
Browse files Browse the repository at this point in the history
  • Loading branch information
Koeng101 committed Jun 28, 2024
1 parent 76d0d1f commit 7d2ea0d
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions lib/tokenizer/cli/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (

func main() {
// Define flags
shardSize := flag.Int("shardSize", int(math.Pow(10, 8)), "Size of each shard") // uniprot sprot splits into 40 files, so 2.5% is retained for validation
shardSize := flag.Int("shardSize", int(math.Pow(10, 7)), "Size of each shard") // uniprot sprot splits into 40 files, so 2.5% is retained for validation
outputDir := flag.String("outputDir", "", "Output directory path")
tremblInput := flag.String("tremblInput", "", "Trembl input directory")
unirefInput := flag.String("unirefInput", "", "Uniref input directory")
Expand Down Expand Up @@ -122,10 +122,14 @@ func main() {
pfamCount++
return true
})
pfamCount := make(map[string]bool)

Check failure on line 125 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, ubuntu-latest)

no new variables on left side of :=

Check failure on line 125 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, ubuntu-latest)

cannot use make(map[string]bool) (value of type map[string]bool) as uint16 value in assignment

Check failure on line 125 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, macos-latest)

no new variables on left side of :=

Check failure on line 125 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, macos-latest)

cannot use make(map[string]bool) (value of type map[string]bool) as uint16 value in assignment
for _, values := range pfamMap {
for _, pfam := range values {
pfamCount++
tokenizer.TokenMap.Store(pfam, pfamCount)
_, ok := pfamCount[pfam]

Check failure on line 128 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, ubuntu-latest)

invalid operation: cannot index pfamCount (variable of type uint16)

Check failure on line 128 in lib/tokenizer/cli/main.go

View workflow job for this annotation

GitHub Actions / test-lib (1.21.x, macos-latest)

invalid operation: cannot index pfamCount (variable of type uint16)
if !ok {
pfamCount++
tokenizer.TokenMap.Store(pfam, pfamCount)
}
}
}
tokenizerJSON, err := tokenizer.ToJSON()
Expand Down

0 comments on commit 7d2ea0d

Please sign in to comment.