dmmiller612 / bert-extractive-summarizer

Easy to use extractive text summarization with BERT
MIT License
1.39k stars 305 forks source link

empty output #44

Closed aceyiyuan closed 4 years ago

aceyiyuan commented 4 years ago

Hi!

I tried this module (v. 0.4.2). It's impressive. One thing I would like to check with you, though. In your example: result = model(text, min_length=60) #this works however when I change the "text " to like this: result =model(df['text_body'][1], min_length=60)# this does not work It generated an empty cell or like this ' ' Why?

How is a little bit more details:

type(text) => str type(df['text_body'][1])=>str

print(df['text_body'][1]) #Note: the text was cleaned

vaccination programs are one of the most effective means of controlling infectious diseases and with the development of oral vaccines and bait delivery systems the elimination of diseases circulating in wildlife populations has become a realistic possibility the largescale oral rabies vaccination orv campaigns that have eliminated foxmediated rabies from western europe and north america and substantially reduced disease incidence in central europe are preeminent examples for the success of such control programs orv programs in foxes are aimed at increasing herd immunity in the target population using oral rabies vaccines distributed into the environment over the past four decades several oral rabies vaccines mainly live replicationcompetent attenuated rabies virus vaccines have been successfully used in orv campaigns in canada for example the erabhk21vaccine virus strain a derivative of the cell culture adapted vaccine virus strain street alabama dufferin sad was the only live attenuated vaccine deployed in fox orv campaigns in europe with the exception of a recombinant vaccinia virus expressing the rabies virus glycoprotein all constructs have been based on live attenuated rabies virus strains derived from the sad bern original sad bernorig vaccine virus strain a successor of the era strain while all these vaccines have been highly efficient in fox rabies control the first generation of sadderived vaccines demonstrated residual pathogenicity in nontarget species particularly in rodents although several cases of vaccine virusinduced rabies were observed even in species other than rodents over the course of vaccination campaigns in a number of countries including germany austria slovenia romania poland and canada such cases were without epidemiological relevance

dmmiller612 commented 4 years ago

From this, it looks like all the punctuation is gone. This with spacy by extracting sentences and doing summarization analysis based on the sentences.

aceyiyuan commented 4 years ago

Ok, got it. I will generate a new CSV file w/o removing punctuations. Thanks!