Skip to content

Commit

Permalink
[SPARKNLP-906] Fix reading suffix (#13945)
Browse files Browse the repository at this point in the history
  • Loading branch information
DevinTDHa authored Sep 7, 2023
1 parent 543faaf commit 7f78be3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ trait ReadOnnxModel {

val wrappers = (modelNames map { modelName: String =>
// 2. Copy to local dir
val localModelFile = modelName + suffix
val localModelFile = modelName
fs.copyToLocalFile(new Path(path, localModelFile), new Path(tmpFolder))

val localPath = new Path(tmpFolder, localModelFile).toString
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ class WhisperForCTCTest extends AnyFlatSpec with WhisperForCTCBehaviors {

// Needs to be added manually
lazy val modelTf: WhisperForCTC = WhisperForCTC
.loadSavedModel("exported_tf/openai/whisper-tiny", ResourceHelper.spark)
.pretrained("asr_whisper_tiny")
.setInputCols("audio_assembler")
.setOutputCol("document")

lazy val modelOnnx: WhisperForCTC = WhisperForCTC
.loadSavedModel("exported_onnx/openai/whisper-tiny", ResourceHelper.spark)
.pretrained()
.setInputCols("audio_assembler")
.setOutputCol("document")

Expand Down

0 comments on commit 7f78be3

Please sign in to comment.