xavierbarbier commited on
Commit
c3e00da
·
verified ·
1 Parent(s): 7d37721

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -6
app.py CHANGED
@@ -5,11 +5,7 @@ import os
5
 
6
  def extract_text(file):
7
 
8
- """path = file
9
- normalized_path = os.path.normpath(path)
10
- normalized_path = normalized_path.replace("\\", "/")
11
-
12
- # creating a pdf reader object
13
  reader = PdfReader(file)
14
 
15
  text = []
@@ -19,7 +15,7 @@ def extract_text(file):
19
  # extracting text from page
20
  text.append(page.extract_text())
21
 
22
- text = ' '.join(text)"""
23
 
24
  return file
25
 
 
5
 
6
  def extract_text(file):
7
 
8
+
 
 
 
 
9
  reader = PdfReader(file)
10
 
11
  text = []
 
15
  # extracting text from page
16
  text.append(page.extract_text())
17
 
18
+ text = ' '.join(text)
19
 
20
  return file
21