In [1]:
import pandas as pd
import numpy as np
import xgboost as xgb
from tqdm import tqdm
from sklearn.svm import SVC
from keras.models import Sequential
from keras.layers.recurrent import LSTM, GRU
from keras.layers.core import Dense, Activation, Dropout
from keras.layers.embeddings import Embedding
from keras.layers.normalization import BatchNormalization
from keras.utils import np_utils
from sklearn import preprocessing, decomposition, model_selection, metrics, pipeline
from sklearn.model_selection import GridSearchCV
from sklearn.feature_extraction.text import TfidfVectorizer, CountVectorizer
from sklearn.decomposition import TruncatedSVD
from sklearn.linear_model import LogisticRegression
from sklearn.model_selection import train_test_split
from sklearn.naive_bayes import MultinomialNB
from keras.layers import GlobalMaxPooling1D, Conv1D, MaxPooling1D, Flatten, Bidirectional, SpatialDropout1D
from keras.preprocessing import sequence, text
from keras.callbacks import EarlyStopping
from nltk import word_tokenize
from nltk.corpus import stopwords
stop_words = stopwords.words('english')
/home/surya/DL/lib/python3.5/site-packages/sklearn/cross_validation.py:41: DeprecationWarning: This module was deprecated in version 0.18 in favor of the model_selection module into which all the refactored classes and functions are moved. Also note that the interface of the new CV iterators are different from that of this module. This module will be removed in 0.20.
"This module will be removed in 0.20.", DeprecationWarning)
Using TensorFlow backend.
In [2]:
import spacy
nlp = spacy.load('en')
In [3]:
train = pd.read_csv('data/train.csv')
test = pd.read_csv('data/test.csv')
sample = pd.read_csv('data/sample_submission.csv')
In [4]:
max_len = max([len(i.split()) for i in train.text.values])
max_len
Out[4]:
861
In [5]:
def multiclass_logloss(actual, predicted, eps=1e-15):
"""Multi class version of Logarithmic Loss metric.
:param actual: Array containing the actual target classes
:param predicted: Matrix with class predictions, one probability per class
"""
# Convert 'actual' to a binary array if it's not already:
if len(actual.shape) == 1:
actual2 = np.zeros((actual.shape[0], predicted.shape[1]))
for i, val in enumerate(actual):
actual2[i, val] = 1
actual = actual2
clip = np.clip(predicted, eps, 1 - eps)
rows = actual.shape[0]
vsota = np.sum(actual * np.log(clip))
return -1.0 / rows * vsota
In [6]:
lbl_encoder = preprocessing.LabelEncoder()
y = lbl_encoder.fit_transform(train.author.values)
In [7]:
x_train,x_valid,y_train,y_valid = train_test_split(train.text.values,y,
test_size=0.5,shuffle=True)
In [8]:
x_train_fltr = [[token.text for token in nlp(doc) if not token.is_stop
and token.text not in ['.',',',':']]for doc in x_train]
x_valid_fltr = [[token.text for token in nlp(doc) if not token.is_stop
and token.text not in ['.',',',':']]for doc in x_valid]
---------------------------------------------------------------------------
KeyboardInterrupt Traceback (most recent call last)
<ipython-input-8-a0ce4de95168> in <module>()
1 x_train_fltr = [[token.text for token in nlp(doc) if not token.is_stop
----> 2 and token.text not in ['.',',',':']]for doc in x_train]
3 x_valid_fltr = [[token.text for token in nlp(doc) if not token.is_stop
4 and token.text not in ['.',',',':']]for doc in x_valid]
<ipython-input-8-a0ce4de95168> in <listcomp>(.0)
1 x_train_fltr = [[token.text for token in nlp(doc) if not token.is_stop
----> 2 and token.text not in ['.',',',':']]for doc in x_train]
3 x_valid_fltr = [[token.text for token in nlp(doc) if not token.is_stop
4 and token.text not in ['.',',',':']]for doc in x_valid]
~/DL/lib/python3.5/site-packages/spacy/language.py in __call__(self, text, disable)
327 ('An', 'NN')
328 """
--> 329 doc = self.make_doc(text)
330 for name, proc in self.pipeline:
331 if name in disable:
~/DL/lib/python3.5/site-packages/spacy/language.py in make_doc(self, text)
355
356 def make_doc(self, text):
--> 357 return self.tokenizer(text)
358
359 def update(self, docs, golds, drop=0., sgd=None, losses=None):
tokenizer.pyx in spacy.tokenizer.Tokenizer.__call__()
tokenizer.pyx in spacy.tokenizer.Tokenizer._tokenize()
tokenizer.pyx in spacy.tokenizer.Tokenizer._attach_tokens()
doc.pyx in spacy.tokens.doc.Doc.push_back()
morphology.pyx in spacy.morphology.Morphology.assign_untagged()
~/DL/lib/python3.5/site-packages/spacy/lemmatizer.py in lookup(self, string)
80 return self(string, 'punct', morphology)
81
---> 82 def lookup(self, string):
83 if string in self.lookup_table:
84 return self.lookup_table[string]
KeyboardInterrupt:
In [ ]:
x_train_fltr
In [36]:
x_train_fltr_join = [' '.join(doc) for doc in x_train_fltr]
x_valid_fltr_join = [' '.join(doc) for doc in x_valid_fltr]
In [37]:
x_train_fltr_join
Out[37]:
['You careful thing downright improviso air',
'In manner I fancied I distinguish precise moment fairly disengaged lid I determine removed altogether deposited lower berth room ; point I knew example certain slight taps lid striking wooden edges berth endeavored lay gently room floor',
'So White Ship sailed past walls Thalarion followed days southward flying bird glossy plumage matched sky appeared',
'God I dare tell I saw',
'Oh beloved father Indeed miserable words truly I forgive entirely possess heart I endeavoured rainbow gleams cataract D soften thy tremendous sorrows',
'At I beheld seething blur luminosity ; shapes infinitely distant began detach confusion I saw Juan Romero ?',
'I wished shake thought feeling I learned means overcome sensation pain death state I feared understand',
'To accomplish great desideratum ærial navigation generally supposed exceedingly complicated application unusually profound principle dynamics',
'It Greenwich Greenwich roof row houses lovely green lanes fields bits grassy common',
'My rage unspeakable I reflect murderer I turned loose society exists',
'After passing months London received letter person Scotland visitor Geneva',
'Nay Henry stand intrusion foe',
'The extreme darkness stage light received fire cauldron joined kind mist floated rendered unearthly shapes witches obscure shadowy',
'A strange story rife',
'I exhausted speak I merely regarded imploring air',
"He knows They trod earth 's fields They tread behold Them They tread",
'Perdita permitted Clara Windsor ; lovely infants perpetual sources interest amusement',
'I knew second ; I remembered frightful castle trees recognised altered edifice I stood ; I recognised terrible unholy abomination stood leering I withdrew sullied fingers',
'Wit hilarity deep observation mingled talk rendering sentence uttered flash light',
"Besides Grace hated scene De L'Omelette",
'Woe befall day thought woe tears mourning betide hour gave Raymond hope love wish devotion ; thrice joyful moment shall restored God knows I trust vows believe asserted faith I seek I resolved attain',
'She employed arranging departure ; promised Raymond decisive evening advantage absence stage journey defeat ascertained slip away join',
'We unhappy ; additional motive son return comforter ?',
'He monstrum horrendum unprincipled man genius',
'Dupin said words low tone quietly',
'This strange tale shake faith ; I replied earnestly " You mistaken ; I know murderer',
'From sprung flesh flesh bone bone heretofore content trace downy cheek delicate limbs affinity Raymond enthusiastic affections sweet qualities mind find living good great beloved',
'What demon urged breathe sound recollection wo nt ebb purple blood torrents temples heart ?',
'From central recess melancholy vaulting depended single chain gold long links huge censer metal Saracenic pattern perforations contrived writhed endued serpent vitality continual succession parti colored fires',
'With fonder regret clung memory ; gave charge son meet valued friend bestow succour assure attachment survived separation silence',
'Visiters enter look furniture depart unheeded unseen',
"About seven o'clock evening died frantic husband frightful scene efforts kill West wildly blamed saving life",
'When crowd gone I saw grave bearded man brought place standing lantern',
'I AM come race noted vigor fancy ardor passion',
'In landscape principle critic true ; having felt truth headlong spirit generalization induced pronounce true domains Art',
'Startled sound I sprang feet gondolier letting slip single oar lost pitchy darkness chance recovery consequently left guidance current sets greater smaller channel',
'Yet lived months nearly state inspire immediate fear ; talked death event familiar thoughts cease exert render happy cultivate astonishing powers mind',
'If I went sleep I proposed atmosphere chamber regenerated interim ?',
'With passage time glad lingered relics youth cleavage world life sophistication distant unreal ; touch magic expectancy stole nightly slumbers',
'I going claim protection friends I sincerely love favour I hopes \' " \' Are Germans ? \' " \' No French',
'I strained vision detect motion corpse slightest perceptible',
'" Alas " said old man gave account tears eyes " wrings heart lord state I heard coming young lady I thought happy days enjoyed short life lady mother But happiness poor creatures born tears taken soon ; beautiful good',
'And like David I try music win evil spirit ; singing I lifted eyes saw fixed filled tears ; muscles relaxed softness',
"We set St. Bartholomew 's entered wretched precincts house disease",
'Yet conceptions formulated rustic words wholly inadequate convey circumstance drove conclusion true dream world existed oral language medium transmission thought',
'This request I confess ?',
"I calc'late man good husban ' ye kin find Aylesbury ; ' ef ye knowed abaout hills I dew ye n't ast better church weddin ' her'n",
'In fit heroism I determined ; quit life life untill I guiltlessly',
'There I suffered remain minutes I strove imagine I',
'As sickness quitted I absorbed gloomy black melancholy dissipate',
'West young despite marvellous scientific acquirements scant patience good Dr. Halsey erudite colleagues ; nursed increasing resentment coupled desire prove theories obtuse worthies striking dramatic fashion',
'In short ingress egress gate occupying rocky pass road paces point I stopped reconnoitre scene',
'I wonder moment instead venting sensations exclamations agony I rush mankind perish attempt destroy',
'At length I saw distance seated tree perceived waved hand times beckoning approach ; unearthly mien awed chilled I drew near',
'Ahead robed black man seen peaked space dream lesser distance old woman beckoning grimacing imperiously',
'Conscious having deserved punishment desirous concealing bloody deeds skipped chamber agony nervous agitation ; throwing breaking furniture moved dragging bed bedstead',
'One night winter I entered box P Theatre company friend Mr. Talbot',
'He admired Mr. John Neal great man small way',
'He exceedingly puffy little old gentleman big circular eyes huge double chin',
'The natural clinging human mind life joy energy young heart ; gave impetuously enchantment married ; radiant features I saw incarnate time spirit love rapturous sympathy life world',
"There talk apportioning Randolph Carter 's estate heirs I shall stand firmly course I believe dead",
'The raising ghosts devils promise liberally accorded favourite authors fulfilment I eagerly sought ; incantations unsuccessful I attributed failure inexperience mistake want skill fidelity instructors',
'My knowledge thing began winter death grand uncle George Gammell Angell Professor Emeritus Semitic Languages Brown University Providence Rhode Island',
'The farm like grounds extended deeply hill Wheaton Street',
'The reduction interval smallest possible dimension object reasoner',
"Found ascending force greater expected ; arose higher got clear cliffs sun 's rays ascent rapid",
'He grew sterner face elderly',
'As doctor bed mutter " But God \'s ? "',
'For long time eat thistles ; idea soon cured insisting eating',
'Through years Wilbur treated half deformed albino mother growing contempt finally forbidding hills May Eve Hallowmass ; poor creature complained Mamie Bishop afraid',
"From nature fabrics thorn nail entangled tears rectangularly divides longitudinal rents right angles meeting apex thorn enters scarcely possible conceive piece ' torn '",
'Although situation dispositions equally cut usual forms social intercourse formed strong contrast',
'He loved guilty passion stung remorse despair killed',
'He gazing gaspingly fascinatedly afraid',
'No man crush " butterfly wheel " better effect ; man better cover speedy retreat powerful adversary',
"The ' Oil Bob ' title masterpiece eloquence art",
'They seen heard cries hamlets knew creeping death come',
'The ultimate life design',
'I left employment Messrs. Cut Comeagain set Eye Sore line lucrative respectable independent ordinary occupations',
'Monsieur Dumas worthy coadjutor Monsieur Etienne pronounced inflicted obtuse instrument ; far gentlemen correct',
'Little things considerable excitement little towns reason Kingsport people talked spring summer unidentifiable bodies horribly slashed cutlasses horribly mangled tread cruel boot heels tide washed',
'It require minutes regenerate atmosphere fullest manner real difficulty contrive method arousing proper moment',
'Yours everlastingly PUNDITA',
'As soon showed signs life wrapped blankets placed near chimney kitchen stove',
'He flushed excited talking high unnatural pedantic voice',
'The door house left open visiter entered ringing advanced steps staircase',
'Eliot old Reid right',
'In meantime certain I attacked Fly attempt composing rival poem " Oil Bob " Mr. Crab attend pointedly private personal interests',
'He heard footsteps crowd overhead endeavored heard turn',
'The scales exceedingly hard glossy appearance burnished gold',
'Yet lovely noble feeling poor Perdita fanciful sister received dying parent altogether saintly disposition',
'With proper caution perseverance shall infallibly trace boat ; bargeman picked identify rudder hand',
'You conceive astonishment hearing question addressed man brink destruction I supposed vessel resource exchanged precious wealth earth afford',
'Ah dear sister I answer question ?',
'I mean way \' de nier ce qui est et d\'expliquer ce qui n\'est pas \' "',
'The glassy roll eye changed expression uneasy inward examination seen cases sleep waking impossible mistake',
'As bathed changed clothes tried recall dreamed scene violet litten space definite crystallise mind',
'No seen closely servants ; disposition violent singular',
'He mentioned tell meant Keziah long toothed familiar haunting young gentleman',
'Professor Angell befitted authority attainments prominent deliberations ; approached outsiders took advantage convocation offer questions correct answering problems expert solution',
"At o'clock took lunch restaurant noting pull lessened divided",
'His ordinary manner vanished',
'At morning I called individual clothes day',
'The Automaton Chess Player invented Baron Kempelen nobleman Presburg Hungary disposed secret operations present possessor',
'I ate breakfast pleasure remove plank procure little water I heard step looking small chink I beheld young creature pail head passing hovel',
'Chapter Nothing painful human mind feelings worked quick succession events dead calmness inaction certainty follows deprives soul hope fear',
'Then I came suddenly noonday solitudes wind heaven intruded vast meadows poppies slender lily looking flowers spread weary distance silent motionless forever',
'A rush cool air greeted ; day hottest late June I shivered I crossed threshold large apartment rich tasteful decoration surprised nest squalor seediness',
'The entire area Pundit says years ago densely packed houses stories high ; land unaccountable reason considered especially precious vicinity',
'Little said ; chief embarrassment lay yelpings dog took exceeding interest proceedings',
'In I underwent kind rough usage ill befitting wounds mind sustained',
'Palaces deserted poor man dared length unreproved intrude splendid apartments furniture decorations unknown world',
'The picture seared soul scene hour long midnight ; waning crescent moon high vaporous heavens',
'He attired I expected costume altogether similar ; wearing Spanish cloak blue velvet begirt waist crimson belt sustaining rapier',
'" The material world " continued Dupin " abounds strict analogies immaterial ; color truth given rhetorical dogma metaphor simile strengthen argument embellish description',
'With great difficulty I gained feet looking dizzily struck idea breakers ; terrific wildest imagination whirlpool mountainous foaming ocean engulfed',
'Fool I plunge unsanctioned phrensy mysteries man meant penetrate ; fool god friend led went end passed terrors',
'But I recovered stupor dawned gradually conviction startled far coincidence',
'But presence child subsequent visit rouse sister',
'" C\'est à vous à faire " said Majesty cutting',
'I stirred feather life issue sullied delicacy mirror',
'I said defects character awoke acquired vigour unnatural position',
'Every awaited heartfelt anxiety reply dignified Smith',
'About noon nearly guess attention arrested appearance sun',
'Just dawn nights I speak I distinctly heard Mr. Wyatt replace lid oblong box force nails old places means muffled mallet',
'It midnight task drawing close',
'But worst shock came uncle shewed Orne jewellery downtown safe deposit vault',
'These wild miserable thoughts I describe eternal twinkling stars weighed I listened blast wind dull ugly siroc way consume',
'Soon alas conquer',
'Clerval continued talking time mutual friends good fortune permitted come Ingolstadt',
'We interrupted attendant announced staff Raymond assembled council chamber',
'Thus I felt disappointment weariness solitude drove heart gather joy barren',
'Having strown fir boughs rested drawn automatics relaxing watched',
'Its rim feet deep',
'It oppressed hideous novelty emotion',
'The head slightly elevated',
'Of course heard matter afterward suffered untold torments black bewildered speculation ; bad actual nearness possible sights',
'To better colouring I contrived assembled party solicitously careful introduction cards appear accidental originate proposal contemplated dupe',
'For I deprived rest health',
'But smaller separate tragedies yield mightier interest promised calm infectious influences tempest arose wilder winds tempest bred passions man nourished violent impulses unexampled dire',
'Mr. Ellison musician poet ; man lived profoundly enamored Music Muse',
'They lot fish lobsters exporting truck',
'Would better visit seized openly departed ? "',
'The jewels saved supported awhile',
'" How inconstant feelings But moment ago moved representations harden complaints ?',
'Oh When guiding spirit conducting daemon allow rest I desire ; I die live ?',
'If I times force abhorred presence remind task contemplate progress ?',
'Yet promises Eleonora forgotten ; I heard sounds swinging censers angels ; streams holy perfume floated valley ; lone hours heart beat heavily winds bathed brow came unto laden soft sighs ; indistinct murmurs filled night air oh I awakened slumber like slumber death pressing spiritual lips',
'The sense falling ceased ; motion vessel belt foam exception lay',
'Their beauty Grecian deformity Egyptian tout ensemble French',
'After followed sharp grating noise shouted gibberish Pickman deafening discharge chambers revolver fired spectacularly lion tamer fire air effect',
'I heard division property immense wealth squalid poverty rank descent noble blood',
'A word outsider relief',
'She continued work whilst young man went garden appeared busily employed digging pulling roots',
'It run seven o\'clock We time slack whirl Ström fury " When boat built properly trimmed deep laden waves strong gale going large slip beneath appears strange landsman called riding sea phrase',
'Wealthy necessity commercial life temperamentally unfitted formal studies social recreations acquaintances I dwelt realms apart visible world ; spending youth adolescence ancient little known books roaming fields groves region near ancestral home',
'" Proceed " I said ; " Amontillado',
'Strange ambition Yet Adrian',
'Yes paper reason I dropped Pickman ; Richard Upton Pickman greatest artist I known foulest leaped bounds life pits myth madness',
'The date I regard remoteness antiquity assignable quantity whatsoever',
'But Wilson ?',
'He disregarded decora mere fashion',
'The scenery presented sides scarcely entitled called grand indescribable delicious aspect dreary desolation',
'dee Hi Hi Randy " A swaying lantern came black bend old Benijah pounced silent bewildered form pilgrim',
'The letters air profundity',
'Neither grief philosophy love Perdita think mildness dereliction Raymond',
'Rome Ravenna rivals honour birth certain received rhetorical philosophical training schools Athens extent suppression Theodosius century grossly exaggerated superficial',
'You find means justify poor guiltless Justine',
'Now suppose I sail position thousand miles east',
'It strange old Gregory desert master telling tried friend I.',
"Spells right suppose n't ?",
'Joy exultation possess save',
'I believe coming determination repulsed I went right forward object weighing replies I led passion drew frantic heedlessness abyss fearfully avoided I replied terrific words " You fill affright true dearest father confirm resolution end state doubt',
'After Barry told things I drowsy travels day wearying host talked late night',
'" When gen\'l\'man wants tuh drink God shall interferin \'',
'They shall bars pit rest dust Yes hope corruption dust death brings',
'Clearly nerves sorely taxed I cast impressions weaker men',
'Dr. Job Ives diagnosed trouble infantile fever declared mere wasting away decline',
"The story 's legion devils seen reef sprawled darting kind caves near",
'In studies far gone know ; scientific pursuit continual food discovery wonder',
'Thus pushing way difficulty narrow snow blocked town I crossed bridge passed Eton',
'I confess I like know precise character thoughts defied Prefect terms \' certain personage \' reduced opening letter I left card rack "',
'All difference pipe somewhat bigger theirs greater smoke',
'There windows',
'He deeply read books chivalry romance',
'August th My affection guest increases day',
'" Her companion wears remarkably " said trio spoken',
'" It juncture Mr. Monck Mason voyage Dover Weilburg balloon " Nassau " occasioned excitement conceived idea employing principle Archimedean screw purpose propulsion air rightly attributing failure Mr. Henson \'s scheme Sir George Cayley \'s interruption surface independent vanes',
'Despite distance I knew servants brought north I recognised ugly unwieldy form cook absurdness unutterably tragic',
'" Smith ? " said known peculiar way drawling syllables ; " Smith ?',
'good wise beloved gone',
'I shivered cracked stroke sounded belfry left',
'His countenance expressed sympathy compassion ; drew chair close addressed French " I fear place shocking ; I comfortable ? "',
'Its general directions I said west east north south',
'" He twice waylaid footpads person rigorously searched inspection "',
'When fumbling came nearer casements crept west flattening wall opened windows',
'I hired men row took oar I experienced relief mental torment bodily exercise',
'But I enjoyed friends dear habit association merits ; I soothing voice Elizabeth conversation Clerval whispered ear',
'It absence idiosyncratic organs attribute nearly unlimited perception ultimate life',
'It found Bois de Boulogne vast distance scene butchery',
"Thet feller bein ' chopped gives tickle time I look ' m I hev ta lookin ' ' m whar butcher cut feet ?",
'The manuscript divided sections headed " Dream Dream Work H. A. Wilcox Thomas St. Providence R.I. " second " Narrative Inspector John R. Legrasse Bienville St. New Orleans La. A. A. S. Mtg',
'Je lui ai cette obligation entre les autres de m \' auoir non seulement mis en main cc Livre en anglois mais encore le Manuscrit du Sieur Thomas D\'Anan gentilhomme Eccossois recommandable pour sa vertu sur la version duquel j \' advoue que j \' ay tiré le plan de la mienne "',
'Turning passage specified read great care closed book desired character confidential acquaintance express Baron von Jung exalted sense chivalrous behavior second assure explanation offered fullest honorable unequivocally satisfactory nature',
'V. Yes ; mind existing unincorporate merely God',
'I " amused " scarcely know explain',
'" My dear Victor " cried " God \'s sake matter ?',
'I strived decypher vain ; anon like spirit departed sound shrill piercing shriek female voice ringing ears',
'The orphan neglected son Verney eve linked mechanism society golden chain enter duties affections life',
'A closer scrutiny assured small calf roasted set knees apple mouth English fashion dressing hare',
'I hate moon I afraid shines certain scenes familiar loved makes unfamiliar hideous',
'He wishes prove Marie assassinated corpse',
'" We know wide world means ; strange mixture good evil',
'Instead hillside tomb charred cellar crest slope presiding daemon beckoned unseen fingers',
'There deep horror tale confidence ; I earth sole depository secret',
'I money gained friendship villagers distributing ; I brought food I killed taking small I presented provided fire utensils cooking',
'And I fear ; I fear things ; state linked chain memory happiness return Paradise I feel love enduring mortal beatings fragile heart pulse knells audibly The funeral note Of love deep buried resurrection',
'How mutable feelings strange clinging love life excess misery I constructed sail dress eagerly steered course land',
'However captain said perceive indication danger drifting bodily shore ordered sails furled anchor let',
'Thus sensation immediate suffering wore I human',
'We equal ; magnificent dwellings luxurious carpets beds afforded',
'And Sefton Asylum mishap West vanished',
'It easier tear new slip petticoat',
'The girl young gentle demeanour unlike I found cottagers farmhouse servants',
'He loved enterprise hardship danger sake',
"You raise dust kindness ; I trust aid I shall driven society sympathy fellow creatures '",
'All',
'These vanes number found entirely ineffectual moving balloon aiding ascending power',
'One man Oriental eyes said time space relative men laughed',
'The feeling predominated',
'It firmly secured bands wrought iron riveted forming kind open trelliswork',
'My ultimate object truth',
'What ? " " But sir I n\'t remember paid tobacco "',
'While spoke profound stillness heard pin drop floor',
"Encouraged encomium I proceeded answer inquiries relate I remembered parent ; gave account circumstances brought neglect father 's testamentary letter",
"What said respect ' detecting bringing practice nice relations size proportion color ' mere vagueness speech mean little guides degree",
'My coming New York mistake ; I looked poignant wonder inspiration teeming labyrinths ancient streets twist endlessly forgotten courts squares waterfronts courts squares waterfronts equally forgotten Cyclopean modern towers pinnacles rise blackly Babylonian waning moons I found instead sense horror oppression threatened master paralyse annihilate',
'I saw writhe deadly locution',
'There tone didactic tone enthusiastic tone natural common place',
'There I remember I remember morning stamp madman genius I dared write',
'It surpassing beauty dazzling fire eyes words rich accents wrapt listener mute extactic wonder transcend appeared formed minister superior excellence',
'Induction posteriori brought phrenology admit innate primitive principle human action paradoxical perverseness want characteristic term',
'The walls bare boards probably known plaster ; whilst abundance dust cobwebs place deserted inhabited',
'It useless describe playing Erich Zann dreadful night',
'But Johansen given',
'When grim Darkness overspread Earth horror thought I shook shook quivering plumes hearse',
'My sensations time distinct mind received day additional ideas',
'He paused lost thought',
'I allow refrain allowing temptation erewhile existed great man tempted certainly fell',
'" Here leave beginning groundwork mere guess',
'The conditions imposed fulfilled letter moment \'s hesitation failure fulfilment decree tied neck heels duly drowned rebels yon hogshead October beer " " A sentence sentence righteous sentence glorious decree worthy upright holy condemnation " shouted Pest family altogether',
'But idea exalting chalking new path ; path action long wandered ?',
'The voice puzzled little ; apparent mystery speedily cleared',
'You found I fearful losing bargain "',
'I lead unguarded ardent I destruction infallible misery',
'Oh believe beheld lips pale grief smile joy gratitude knew parent smile feel pure warm happiness wish live enjoy pleasure',
"I recall things Sam Johnson Club having kept Membership Latter long Doctor 's Death I sincerely mourn'd",
'The fact good deal puzzled affair simple baffles altogether "',
'At length valley pained memories Eleonora I left vanities turbulent triumphs world',
'" And " said Raymond " I advise seeing',
'The beatings human heart drew blank reality',
'The second impression far vivid enthusiasm',
'Shall I voice deep ; hollow ; gelatinous ; remote ; unearthly ; inhuman ; disembodied ?',
'The morning taken knowledge officers',
'The family connected way Maelzel Automaton chess player memory',
'Pestilence future existence ; guarded like flooding rivers encroachments ocean inclemency sky',
'I shall satiate ardent curiosity sight world visited tread land imprinted foot man',
'A shudder like swift passing electric shock ran house Rosse exclaimed answer " Stands Scotland ? "',
'But mysterious allies coherent account gained',
"They haunting memory face modelled marble base carven single letters Attica ' ΥΠΝΟΣ.",
'Swooning I staggered opposite wall',
'My opinion paragraph founded principally manner',
'Adrian observed change visit afterward paid ; tell extent divine cause',
'Dogs fear felt outside shadow left',
"Once hinted child Dutee somewhat peculiar circumstance Mercy 's moments soon forgotten save peculiar",
'" To sure " said I " sure They behave little odd eh ? little queer eh ? n\'t think ? " " Odd queer think ?',
'You find discovery followed immediately urgent communications sent evening paper',
'I continued story " But good champion Ethelred entering door sore enraged amazed perceive signal maliceful hermit ; stead thereof dragon scaly prodigious demeanor fiery tongue sate guard palace gold floor silver ; wall hung shield shining brass legend enwritten Who entereth conqueror hath bin ; Who slayeth dragon shield shall win ; And Ethelred uplifted mace struck head dragon fell gave pesty breath shriek horrid harsh withal piercing Ethelred fain close ears hands dreadful noise like whereof heard "',
'Loss property hopelessness future prospects inoccupation poverty condemned combined reduce state bordering insanity',
'He come triumphantly district parent fled broken hearted ; find ill fated offspring bequeathed vain confidence royal father miserable paupers',
'Many covered eyes hands plunged blindly awkwardly race escape ; overturning furniture stumbling walls managed reach doors',
'Nevertheless confirmed instinctive opinions concurrence compeers',
'On birth second son junior seven years parents gave entirely wandering life fixed native country',
'You perceive lamb goat satyr resemblance Pan Arcadians',
'You observed profound self cognizance evinced sleep waker extensive knowledge displays points relating mesmeric condition ; self cognizance deduced hints proper conduct catechism "',
"D'ye want skeer yer Aunt Marthy plumb death ?",
"He 's beatin'est boy fer runnin ' woods I ; haff time settin ' moonin ' raound snake den upper timber lot",
'" It \'s goin\' agin \' time day It \'s aout \'s aout \' movin \' minute \' Lord knows \'ll " The speaker panted silence took message',
'A " fine old English gentleman " grand uncle Rumgudgeon unlike song weak points',
'" From I observed " said Ellison " understand I reject idea expressed recalling original beauty country',
'Shortly afterward pale faced workmen apprised Superintendent failure',
'Considering topography finally concluded daemon come way Cone Mountain wooded southern prolongation ran short distance westernmost spur Tempest Mountain',
'" Having arranged dwelling carpeted clean straw I retired I saw figure man distance I remembered treatment night trust power',
'In flourishing times Roman Empire ordinary station prefect eastern provinces ; emperors queen city mentioned especially Verus Valens spent greater time',
'" These appearances bewilder merely electrical phenomena uncommon ghastly origin rank miasma tarn',
'I length able write genuine Blackwood article determined forthwith',
'This poor man learned La Place guileless unforeseeing child point starvation pale wife numerous offspring felt hunger observed distress',
'Nor like strange sculptures grey monoliths Ib sculptures terrible great antiquity',
'Having pulled bag way formed complete enclosure sides necessary fasten mouth passing material hoop net work words net work hoop',
'Rushing newly opened connexion I succeeded bolting northerly hall door lock turned ; I I heard hall door room window I hoped reach roof tried pass key',
'Piles death furniture floundered',
'We suggest box apparently board inches thickness spectator satisfy stooping looking main compartment open reality thin',
'Perhaps better',
'The boat glides commences rapid descent vast amphitheatre entirely begirt purple mountains bases laved gleaming river extent circuit',
'And man trembled solitude ; night waned sat rock',
'Frankenstein daily declined health ; feverish fire glimmers eyes exhausted suddenly roused exertion speedily sinks apparent lifelessness',
'Thus long I cradled heart retrospection past happiness hope',
'So youth answered " I Iranon come Aira far city I recall dimly seek find',
'I rest times I accomplish manoeuvre length accomplished',
'To die laughing glorious glorious deaths Sir Thomas More fine man Sir Thomas More Sir Thomas More died laughing remember',
'" Treason " said little man gout',
'" Then \' The Involuntary Experimentalist \' gentleman got baked oven came alive certainly turn',
'My impulse visit enter temple inexplicable imperious command ultimately denied',
'For moment I experienced pangs suffocation ; I blind deaf giddy ; invisible fiend I thought struck broad palm',
'Even I dispatched distant field',
'He said gone sleep afternoon sundown drinking liquor',
'" This experience place like I student life n\'t want miss experience',
'My companion nature content fare',
'From bowers view came bursts song snatches lyric harmony interspersed faint laughter delicious I urged rowers onward eagerness reach scene',
'A shriek heard neighbour night ; suspicion foul play aroused ; information lodged police office officers deputed search premises',
'It low dull quick sound sound watch makes enveloped cotton',
'Dazedness uppermost I scarcely recall dream reality',
'The eye wandered object object rested grotesques Greek painters sculptures best Italian days huge carvings untutored Egypt',
'I went presentiment evil',
'On hand bound principle honor confess know',
'And years men built cabins south The Street',
'In scrutinizing edges paper I observed chafed necessary',
'After I perceive',
'" And " said cadaverous looking personage near foot table taking thread conversation broken " oddities patient time pertinaciously maintained Cordova cheese went knife hand soliciting friends try small slice middle leg "',
'Fortunately storage batteries capable long use interior lighting searchlight',
'It confused recollection I bring mind circumstances meeting',
'This reason body man resume situation cupboard dark defy scrutiny',
'I think approaching years age deep lines face wan hollow cheeked oval actually beautiful ; touches grey thick waving hair small beard deepest raven black',
'Meanwhile poor Rhoby Harris madness gave voice dreams imaginings hideous sort',
'Many pillars palaces tinted marble carven designs surpassing beauty',
'Upon characters engraven stone ; I walked morass water lilies I came close unto shore I read characters stone',
'At times repeated favourite poems drew arguments supported great ingenuity',
"From queenly possessor La Bellissima Duc De L'Omelette peers empire conveyed happy bird",
'A murmur approbation rose speech',
'After quarters hour sign life disappointedly pronounced solution inadequate determined opportunity try change formula disposing ghastly prize',
'Gilman half involuntarily moving twilight abysses bubble mass small polyhedron floating ahead noticed peculiarly regular angles formed edges gigantic neighbouring prism clusters',
'And overhead scarce degrees zenith glowed watching Pole Star',
'Woodville free evils ; slight examples come notice passed course angel winged feet glide earth unimpeded little obstacles earthly origin stumble',
'What moderns know life forces ?',
'After short repose I prepared leave I endeavour accomplish wish',
'I said I alarmed soul deadly material daylight world New York man harmless eccentric wielder dangerous arts I choice save follow slake sense wonder offer',
'I indifferent school fellows general ; I united bonds closest friendship',
'" How reward offered ? " asked Dupin',
'The bar inches half deep neck little bit skin cut',
'I perceive',
'The common conclusion affair simply X traordinary X plicable',
"At length saw numerous steeples London St. Paul 's towering Tower famed English history",
'We moved hands example dwellers earth gave vibration atmosphere engirdled',
"Now I 'll way accomplishing point",
'Had Kidd concealed plunder time reclaimed rumors scarcely reached present unvarying form',
"It beating old man 's heart",
'Thus thing profound',
"heh heh heh Matt Eliot Mason ' agin ' sellin ' dropped aout o ' sight jest",
'He bowed I presented ; grave countenance motioned seat',
'And I wept ; yes warm tears struggled eyes soothing bitter ; I wept called unavailing anguish outstretched arms cruel father ; weak frame exhausted variety plaint I sank reverie reflected I find I desired ; dear aught dear death like solitude',
'Did observe thing peculiar ? "',
'The valet threw open door ushered presence master',
'In summing evident reasoner succeeded convincing',
'" And " said friend whispered " Boullard tee totum',
'Another hickory larger elm altogether finer tree exceedingly beautiful taken charge northwestern entrance springing group rocks jaws ravine throwing graceful body angle nearly degrees far sunshine amphitheatre',
'In instant I precipitated misfortune fracture arm',
'My observation way opening masked battery',
'My brain reeled I hearkened entranced melody mortal assumptions aspirations mortality known',
'" When gone Jupiter fast asleep I betook methodical investigation affair',
'I felt matters pupil',
'Could suppose oversight oversight remedied fourth',
'When servant came gave letter',
'He declared notwithstanding harshness called coldness loved',
'She looked steadily life assumed duties courage zeal',
"At evening Iranon sang sang old man prayed blind man said saw nimbus singer 's head",
'It formed light wicker wonderfully strong frail looking machine',
'His action alternately vivacious sullen',
'I suppose astonishment exhibited countenance Mr. Kirwin hastened " Immediately taken ill papers person brought I examined I discover trace I send relations account misfortune illness',
'They worshipped said Great Old Ones lived ages men came young world sky',
'I said child grew strangely stature intelligence',
'Still I hurry ; I pause recollections happy weeks ; I repeat word I remember record enchantment faery habitation',
'For century appeared Roulets remembered frequently discussed vivid incidents quiet life New England seaport',
'It adversities hurt instead purifying heart ; intense misery hardens dulls feelings',
'I knew',
'She hung head said syllable reply',
'If moment shewed curiosity eyes fell voice died away evident suffering quickly endeavour banish ideas awakened ; mingled consolation talk tried soften despair demonstrations deep sympathy compassion',
'As I considered inevitable end mind ran preceding events developed hitherto dormant impression caused weaker superstitious man shudder',
'As I turned promontory I perceived small neat town good harbour I entered heart bounding joy unexpected escape',
'In violent eddies sea good fishing proper opportunities courage attempt ; Lofoden coastmen ones regular business going islands I tell',
'Old Waldron curtailed activities rest impossible thing close great results equations',
'Had eyes deceived ?',
'In volume " American Quarterly Review " found elaborate criticism certain " journey " kind question criticism difficult critic exposes stupidity book absurd ignorance astronomy',
'By taught carry parcels weight weight gradually increased',
'A flash lightning illuminated object discovered shape plainly ; gigantic stature deformity aspect hideous belongs humanity instantly informed wretch filthy daemon I given life',
'The usual imports entirely cut',
'" Still I understand " said Dupin',
'My imagination hung scene recognition ; miniature I continually wear exposed breast means I imaged moment mind thousand thousand times perpetually varying circumstances',
"It merely uncle 's facial expression disturbed doubt strange dreams situation prompted betrayed considerable agitation characteristic",
'The stars came shedding ineffectual glimmerings light widowed earth',
'At relieved famine grave watched Raymond tenderest assiduity feeling repose peculiar convalescence Evadne gave rapturous gratitude love',
'But educated thought erred continually intensity investigations',
'Now Maisons de Sante clear ignoramus misled',
'Many attempts set aside singular bequest ; ex post facto character rendered abortive ; attention jealous government aroused legislative act finally obtained forbidding similar accumulations',
'Excellent paths material nicely adapted velvety sod filling frequent intervals stones led hither thither house crystal spring paces road houses lay north brook thoroughly concealed locusts catalpas',
'" At minutes o\'clock short time prior closing mouth chamber mercury attained limit ran barometer I mentioned extended construction',
'Adrian matchless brother soul sensitive excellent Adrian loving beloved destined find half complete happiness',
'A nervous fever consequence ; nursed daughter poor cottager roof lodged',
'It February thing finally occurred',
'She lit thing greatest distinctness oh God scene light " I attempts speak brother manner I understand din increased I hear single word I screamed voice ear',
'In happiest days Perdita adorned cottage aid art bring nature selected favour',
'Is possible germ actual contagious madness lurks depths shadow Innsmouth ?',
'If came Arkham I stop I asked agent tell',
'Soon shrieks attained magnitude quality written faint I think',
'The bandage jaws silk handkerchief I bound head default customary nightcap',
'I waste days describing anxiously I watched change fleeting circumstance promised better days despair I found effort aggravated madness',
"There 's certain change personal appearance",
'The possession treasures gave extreme delight ; I continually studied exercised mind histories whilst friends employed ordinary occupations',
'All egress chamber window cut',
'" The region I speak dreary region Libya borders river Zaire',
"A portion form tightly stretched partitions necessity removing changes man 's position viz partition rear main compartment rear cupboard No partition main compartment space drawer open",
'Our seclusion perfect',
'The delight Clerval proportionably greater ; mind expanded company men talent found nature greater capacities resources imagined possessed associated inferiors',
'In Greece I learnt love ; waywardness self abandonment impulses superstition attached doubly ; weakness antipodes grovelling selfish',
'They impatient angry midst terror',
'Rushing force fatal hogshead October ale Hugh Tarpaulin rolled instant',
'You dare \' " \' Frankenstein belong enemy I sworn eternal revenge ; shall victim \'',
'The instrumental performers superior talents',
'My steps sure afford single result',
'This dissipate equivocal sensations hitherto annoyed',
"I saw Raymond 's coal black charger brought palace gate ; small company officers arrived soon ; care fear painted cheek eye unrefreshed sleep",
'" I want whiskey good old fashioned rye " exclaimed Trever enthusiastically',
'After motion seconded Lord Raymond rose countenance bland voice softly melodious manner soothing grace sweetness came like mild breathing flute loud organ like voice adversary',
'The pitiable condition dupe thrown air embarrassed gloom ; moments profound silence maintained I help feeling cheeks tingle burning glances scorn reproach cast abandoned party',
'Scarcely I dropped head original position flashed mind I better describe unformed half idea deliverance I previously alluded moiety floated indeterminately brain I raised food burning lips',
'He gave old Matt best skill produce thrifty save rejected specimen use Asaph Sawyer died malignant fever',
'A larger man guided steps ; repellent hulk bluish face half eaten away unknown malady',
'The country afforded mass horrors ; solitary wretches died open fields ; I found survivor vacant village contending famine disease ; assembly pestilence banqueting hall death spread London',
"Oh I kin tell ye little pitchers hev big ears ' I wa'n't missin ' nothin' o ' gossiped abaout Cap'n Obed ' folks aout reef Heh heh heh Haow abaout night I took pa 's ship 's glass cupalo ' seed reef bristlin ' thick shapes dove quick soon 's moon riz ?",
'And unhappy avoid society',
'I married early happy find wife disposition uncongenial',
'" Git aout o \' Git aout o \' They seen git aout fer life Dun\'t wait fer nothin\' know naow Run fer quick aout o \' taown " Another heavy wave dashed loosening masonry bygone wharf changed mad ancient \'s whisper inhuman blood curdling scream',
'In attempting explanation Automaton place endeavor operations effected describe briefly possible nature observations deduced result',
'This idea having seized fancy greatly excited I lost forthwith revery',
'Then came sort island higher ground line passed shallow open cut choked bushes brambles',
'The language discourse clothed debased form Latin use learned men Middle Ages familiar prolonged researches works old alchemists daemonologists',
'If I succeed months years pass I meet',
'A snowy white gauze like drapery nearly sole covering delicate form ; mid summer midnight air hot sullen motion statue like form stirred folds raiment vapor hung heavy marble hangs Niobe',
'Report spoken possessions terms I ventured terms ridiculous exaggeration',
'Liberty useless gift I I awakened reason time awakened revenge',
'CHAPTER I. HEAR YOU rushing sound coming tempest ?',
'Her present visit London tended augment state inquietude shewing utmost extent ravages occasioned pestilence',
'Upon awaking stretching forth arm I found loaf pitcher water',
'Idris smiled thanks rose leave',
'He means anticipate imagines objection theory viz body kept shore days suffering rapid decomposition rapid immersed water',
'" True " said G. ; " conviction I proceeded',
'The ghastly pallor skin miraculous lustre eye things startled awed',
"Perdita 's joined ; conjugal felicity celebrated authentic testimony facts",
'To hear discussing ways means ghastly college procured anatomical specimens',
'I constantly consulted watch light electric lantern listened feverish anxiety receiver telephone ; quarter hour heard',
'" But I change better " Cast " says captain',
'There attendants home ; absconded merry honor time',
'The light conflagration fade away ; ashes swept sea winds',
'" Referring beginning cryptograph find combination',
'Happy happy earth Fit habitation gods short time bleak damp unwholesome',
'Look I labored I toiled I wrote Ye Gods I write ?',
'Here written urgent communications journals way corroboration',
'I need conjure look links existed broken',
'We landed proceeded Paris',
'The Ourang Outang escaped chamber rod break door',
'Nations bordering infected countries began enter plans better keeping enemy',
'It arrived inductive reasoning',
'She resided palace Sweet Waters summer seraglio Sultan ; beauty surrounding scenery undefiled war freshness river spot doubly delightful',
'Do remember story tell Abernethy ? "',
'A touch colour came cheeks hitherto chalk white spread curiously ample stubble sandy beard',
'This madness pride resolution ; wonder pride tameless resolution unalterable "',
'In second I accursed mansion shivering gibbering',
'She child married ; mother Madame Moissart fourteen led altar',
'The mind flags beneath weight thought droops heartless intercourse sole aim amusement',
'At length rose composed miserable',
'I read scrolls Syria Ægyptus cryptic towns Etruria talked length bloodthirsty priest Diana Aricina temple woods bordering Lacus Nemorensis',
'We talked night day I chiselled busts carved miniature heads ivory immortalise different expressions',
'Under idea initiating scene English politics society I soon narrated number anecdotes sketched characters ; discourse rich varied flowed pervading senses pleasure',
'You little I think eh ? " " How ? way ? \' " Why puff puff puff puff employ counsel matter eh ? puff puff puff',
'She answered reasonings briefly declaring disdain reason ; I persuade past unacted maturity cradle useless assure real change taken place fate',
'The magistrate appeared perfectly incredulous I continued attentive interested ; I saw shudder horror ; lively surprise unmingled disbelief painted countenance',
'Poor fellow lay stretched bed sickness cheeks glowing hues fever eyes half closed breath irregular difficult',
'Curiously chiselled badly proportion scenic background ; creatures shewn act killing whale represented little larger',
'Still shocking products experiments grisly masses flesh dead West waked blind brainless nauseous animation',
'Soon inquired I thought breaking ice destroyed sledge',
'It inch horns face jaw like "',
'I Suky Snobbs',
'There numerous mathematical truths truths limits relation',
'But gate swung wider sorcery drug dream pushed I knew sights glories end ; new realm land sea white void unpeopled illimitable space',
'We sure nearly day quarrel yielding publicly palm victory manner contrived feel deserved ; sense pride veritable dignity kept called " speaking terms " points strong congeniality tempers operating awake sentiment position prevented ripening friendship',
'For time looked wide extent country visible terrace saw rays sun tinge dark masses wood variegated autumnal tints ; uncultivated fields smokeless cottages lay shadow ; Thames wound wide plain venerable pile Eton college stood dark relief prominent object ; cawing myriad rooks inhabited trees little park column thick wedge speeded nests disturbed silence evening',
'His stature gaunt tall Legs confounded behold figure emaciated',
'On hearth thick tresses thick tresses grey human hair',
'And King bade away tattered purple clothed satin cloth gold rings green jade bracelets tinted ivory lodged gilded tapestried chamber bed sweet carven wood canopies coverlets flower embroidered silk',
'The thing crowded images time',
'Therein dreamed flames suffocation mountains mountains Pelion Ossa',
'Alien art literature sane balanced readers know recognised thing hinted forbidden Necronomicon mad Arab Abdul Alhazred ; ghastly soul symbol corpse eating cult inaccessible Leng Central Asia',
'Day hateful dawned ; I retreated lodgings I threw couch I slept sleep ?',
'All I recalled classic youth came lips horrors situation roused deepest superstitions',
'I knew acquaintance wealthy',
'For moments I gazed delight dark eyes fringed deep lashes lovely lips ; presently rage returned ; I remembered I forever deprived delights beautiful creatures bestow resemblance I contemplated changed air divine benignity expressive disgust affright',
'At length I took courage hesitate step firmly ; endeavoring cross direct line possible',
'While ascertain validity affidavits I examine newspapers generally',
'The difficulty breathing diminished slight degree I found soon positively necessary use condenser',
'Groping masonry margin I succeeded dislodging small fragment let fall abyss',
'The undergoing rapid change water usually transparent',
'They old folk dwelt higher hills spoke choppy language Vascones understand',
'Geological considerations dictated extension directly downward deepest subterranean area ; belief Superintendent solid rock encountered led placing prodigious charge dynamite',
'I saw fine driven matter course simplicity deliberately induced matter choice',
'Indeed I fear account',
'If humanly possible I use ; I risk street wandering nearest intact highway bridge',
'Take mould possess heart soul eternity',
'I entirely wrapt reverie I wandered taking heed steps I actually stooped gather flower wreath bleak plain flower grew I awoke day dream found I knew',
'On upper stone lay white petticoat ; second silk scarf',
'Something evidently drawn crowd place',
'It late afternoon reached ; quarter great distance resided',
'Steam suffered entirely despite departure hands shore ; work moments feverish rushing wheel engines Alert way',
'What prompted disturb memory buried dead ?',
'Went theatre look Gruff',
'To crown golden gemmed crown I hope ; I dare trust I dream crown wake anon busy devil whispers fool \'s cap I seek I wise I trample stead worth crowns east presidentships west "',
'How miraculous appear The huts neater cottages stately houses engaged admiration turns',
"Heard distinctly ' sacré ' ' mon Dieu '",
'Yet memory replete horror horror horrible vague terror terrible ambiguity',
"South frightful precipice Kingsport north vertical drop nearly mile river 's mouth",
"This morning great joy o'clock surface moon frightfully near apprehensions excited utmost pump condenser length gave evident tokens alteration atmosphere",
'He rode town visiting wounded giving orders necessary siege meditated',
'It came gentle visitation ; went I hardly felt loss',
'My parents dying bequeathed rich legacy',
'Nevertheless seen nature singular exciting',
'Then I thought renewed force factory inspector heard night mouldering pestilential building',
'All bones right leg arm shattered',
"Old Benijah Corey Uncle Christopher 's hired man aged far times boyhood visits",
'We passed innumerable vessels kinds endeavoring beat lying',
'An indefinite sense awe sight navigators ship taken hold mind principle concealment',
'But means natural arrangement',
'Barzai knew gods tell comings goings guessed secrets deemed half god',
'They lived immense houses Washington Street reputed harbour concealment certain living kinsfolk personal aspect forbade public view deaths reported recorded',
'The main compartment speaking portion box visible opening doors shall main compartment lined dark cloth contains machinery pieces steel quadrant shaped situated rear corners compartment',
'But course chances finder repair address given diddler pointed rightful proprietor',
'Again I passed remembrance different scenes short life world stage I merely actor strange alas tragical',
'At events trace science remote period antiquity',
'There intelligence combined innocence sensibility forbearance seriousness perfect good humour beauty transcendant united endearing simplicity hung like pearl shrine possessions treasure wonder excellence',
'All long engaged attention suddenly grew despicable',
'Since encampment daily hourly visits thoughts',
'The country neighbourhood village resembled greater degree scenery Switzerland ; lower scale green hills want crown distant white Alps attend piny mountains native country',
'The small garrisons drawn towns fortresses went swell main army',
'" I forget arms "',
'DURING autumn tour extreme southern provinces France route led miles certain Maison de Sante private mad house I heard Paris medical friends',
'Alas human reason He accused Greeks superstition faith lent predictions Evadne ?',
'She died approach cold weather beginning winter',
"He found spectral gossip town diminished fact notwithstanding certain reports ghostly tittering deserted house lasted long edifice fresh appearances old Keziah Brown Jenkin muttered Gilman 's death",
'A boat lowered echoed deck',
'Besides human tissue West employed reptile embryo tissue cultivated singular results',
'Having measure satisfied curiosity regard extent situation general appearance city I leisure survey church I delicate architecture steeple',
'If I grieved mother I loved image ; sole emotions filled heart quietness',
'He upright noble aught conscience approve ; I know crime involuntary feeling ascribed tumultuous starts gloomy looks wholly struggles mind partly worst fiend Remorse',
'Remember affection hear',
'" For nose " shouted Grace',
'Steeled old ordeals dissecting rooms doctor entered looked stifling nausea mind body sight smell induced',
'He struck space time elapsed madness reasonable impulse regulated actions',
'" The child struggled loaded epithets carried despair heart ; I grasped throat silence moment lay dead feet',
'First visit Evadne hasten palace Protectorate',
'The conditions sentience imagined fulfilled method collocation stones order arrangement fungi overspread decayed trees stood long undisturbed endurance arrangement reduplication waters tarn',
'He listened haughtiness replied disdainfully ; truth succeeded awakening conscience sole effect sought opiate pang oblivious riot',
'The ultimate unparticled matter permeates things impels things things',
'" Justine Moritz Poor poor girl accused ?',
'The prospect sublime',
'It design originally wait physicians ; I induced proceed urgent entreaties M. Valdemar secondly conviction I moment lose evidently sinking fast',
"Then hill 's crest I saw Kingsport outspread frostily gloaming ; snowy Kingsport ancient vanes steeples ridgepoles chimney pots wharves small bridges willow trees graveyards ; endless labyrinths steep narrow crooked streets dizzy church crowned central peak time durst touch ; ceaseless mazes colonial houses piled scattered angles levels like child 's disordered blocks ; antiquity hovering grey wings winter whitened gables gambrel roofs ; fanlights small paned windows gleaming cold dusk join Orion archaic stars",
'The effect scene incantation communicated portion power followed',
'Dances modern cemeteries freely pictured conception shocked rest scene unknown vault scores beasts crowded held known Boston guide book evidently reading aloud',
'The death William execution Justine murder Clerval lastly wife ; moment I knew remaining friends safe malignity fiend ; father writhing grasp Ernest dead feet',
'If I somewhat extravagant imagination yielded simultaneous pictures octopus dragon human caricature I shall unfaithful spirit thing',
'Elwood scarcely dared touch gradually screaming writhing subsided',
'He came sea Constantinople Athens',
'THE " Red Death " long devastated country',
'That man race extinct I saw " born "',
'I child lack companionship fact entailed augmented strange care exercised aged guardian excluding society peasant children abodes scattered plains surround base hill',
'Again I I know Harley Warren ; I think hope peaceful oblivion blessed thing',
'Clinging dastard feeling aged remnant spent life hearing pestilence come neighbourhood barred door closed casement refusing communicate',
"West experimenting madly find start man 's vital motions anew stopped thing death encountered ghastly obstacles",
'Meantime excitement increased hourly',
'At astonished startled considering lack response recent knocking door I immediately afterward concluded walker awakened sound sleep ; listened surprise footsteps sounded creaking stairs',
'To queries person utterly insensible I endeavored place member company mesmeric rapport',
'Indeed crumbling adobe hut closing rock fissure subsequent avalanche helped efface scene recollection',
"Anguish deprived presence mind ; gave Clara physician 's nurse 's parts ; sat bed holding little burning hand glazed eyes fixed babe passed long day unvaried agony",
"couple o ' weeks later nothin' ben throwed sea fer long",
'This difference sufficient cause body sink general rule ; insufficient cases individuals small bones abnormal quantity flaccid fatty matter',
'My dream recurred thoughts ; I usually superstitious wretchedness',
'PERHAPS exhibition kind elicited general attention Chess Player Maelzel',
'Pompey held dirt hands',
'But O Lionel kingdom word gently sounding terms compose style royalty',
'Sometimes thought I felt deeply degradation obliged answer charge murder endeavoured prove futility pride',
'" The revolution Fay " continued I musingly " cycle brief year life',
'It hurt destroyed',
'The withdrew world wonderful dreams ; futile try describe paper',
'Once heart sat lightly bosom ; beauty world doubly beautiful irradiated sun light shed soul',
'When time correspond ones friends',
'Then began ascend stairs joined attic',
'Keep " The combined shock revelation abrupt command gave kind paralysis terror mind opened impressions coming Tillinghast called " "',
"Do n't syllable Infernal Twoness",
"Of bruises body Madame L'Espanaye I speak",
'With friend Joel Manton I languidly disputed',
'Two titan swaths destruction stretched glen Frye farmyard monstrous prints covered bare patches ground old red barn completely caved',
'Still came',
'A diddler stations bridge respectfully informs passers new county law establishes toll cent foot passengers horses donkeys forth forth',
'" Extremely singular " said young Baron musing air apparently unconscious meaning words',
'Beyond doubt similar nature greatly tasking faculty analysis',
'By strange fatality Juliet escaped waited relatives smoothed pillow death',
'When died tide love resumed ancient flow deluged soul tumultuous waves gave prey uncontrollable power',
'In Sona Nyl pain death tell lies basalt pillars West ? "',
'The labours men genius erroneously directed scarcely fail ultimately turning solid advantage mankind "',
'In enthusiasm I nearly idiotic sentimental poor Klenze tardy noticing southward current ceased allowing U settle slowly sunken city aëroplane settles town upper earth',
'The astonishment I experienced discovery soon gave place delight rapture',
'She unaware letter possession proceed exactions',
'" Felix conducted fugitives France Lyons Mont Cenis Leghorn merchant decided wait favourable opportunity passing Turkish dominions',
'They come stars brought Their images Them',
"The impatience sister 's disposition returned awakened repentance sharpened remorse",
'Besides trinket discover information desire',
'Her letter Raymond gave clue discovery ; assured danger wanting means life ; promised preserve future day present station unworthy',
'The callers house find Lavinia ground floor odd cries footsteps resounded boarded second story',
'I struggled vainly firmness sufficient answer effort destroyed remaining strength ; I sank chair sobbed aloud',
'Pestilence usher presence',
'Overreaching wide horizon rainbow How beauty I derived type unloveliness ?',
'My trifling occupations time amuse I rewarded exertions seeing happy kind faces',
'She left I continued time walking passages house inspecting corner afford retreat adversary',
'I follows " M.',
'Believed Madame L. told fortunes living',
'Here I cease repine add tardy consent decree taken',
'Its interior apparently filled wheels pinions levers machinery crowded closely eye penetrate little distance mass',
'The authorities Tulane University shed light cult image detective come highest authorities country met Greenland tale Professor Webb',
'Alludes frequent repetition phrase la tendre Zaire French tragedy',
'My ancestors years counsellors syndics father filled public situations honour reputation',
'But instance occurred occasioned surprise second surprise elevated astonishment ; astonishment profound extreme I horrific',
'From time quitted London fatal night defeat gaming table king received tidings concerning ; lapse years exerted discover trace lost',
'His castles number',
'And brow lofty thought eye wild care ; furrows cheek I read fables sorrow weariness disgust mankind longing solitude',
'Be witnesses " took star insignia office breast threw table',
'To gain partial relief general tension I busied transferring hardware vacant place aid handy device including screw driver I kept key ring',
'Then pursued enemy wings feet flew apartment dismissed attendants locked doors threw wildly floor bit lips blood suppress shrieks lay long prey vulture despair striving think multitudinous ideas home heart ; ideas horrid furies cruel vipers poured swift succession jostle wound worked madness',
'His paroxisms passion terrific soul bore triumphant destroyed victory ; day finally won I foolish presumtuous wretch hurried untill recall hope',
'As spoke earnest eyes fixed read soul heart savage revengeful heart felt influence sweet benignity sink ; thrilling voice like sweetest melody awoke mute echo stirring depths life blood frame',
'Those Old Ones gone inside earth sea ; dead bodies told secrets dreams men formed cult died',
'Now case versed sine thickness segment beneath equal elevation elevation point sight surface',
'The ultimate body escapes rudimental senses perceive shell falls decaying inner form ; inner form ; inner form shell appreciable acquired ultimate life',
'So I tried read soon tremblingly absorbed I found accursed Necronomicon ; thought legend hideous sanity consciousness',
'Before I protested unnatural pryings unthinkable ; evidently succeeded degree I shared spirit terrible cost victory appeared',
'Other feelings ambiguous called play conciliating manner generous warmth expressions respect rarely experienced admiration love touched rocky heart magic power stream affection gushed forth imperishable pure',
'Jewel Lake lay scene action heaved tempest',
'The lady lived ; redoubled ardor I betook task restoration',
'" I ask thing ; I fear His hell I ; I desire His heaven let die laid ; let I lie dead feel flesh moulders mingle theirs',
'We mean harm',
'He accosted excessive warmth drinking',
'His impassioned lectures defence Villon Verlaine Oscar Wilde applied short Indian summer glory talk renewed engagement certain cultured home Park Avenue',
'Some sealed intact nearly vanished leaving silver handles plates isolated amidst certain curious heaps whitish dust',
'What said detecting bringing practice nice relations size proportion color mere vaguenesses speech serve veil inaccuracy thought',
'What nature urging pain misery ?',
'No woman inflicted blows weapon',
'Make happy I shall virtuous "',
'The body twitched vigorously beneath avid eyes commenced heave frightful way',
'I rich young guardian appointed ; act I great society I secret I cut',
'A sombre beautiful peaceful gloom pervaded things',
'Warped bigoted preconceived illusions justice freedom consistency cast old lore old ways old beliefs ; stopped think lore ways sole makers present thoughts judgments sole guides standards meaningless universe fixed aims stable points reference',
'At came I long feared',
'I mentioned Perdita',
"Then mighty art thou O wind throned vicegerents nature 's power ; thou comest destroying east pregnant elementary life west ; thee clouds obey ; sun subservient thee ; shoreless ocean thy slave Thou sweepest earth oaks growth centuries submit thy viewless axe ; snow drift scattered pinnacles Alps avalanche thunders vallies",
'The form monster I bestowed existence forever eyes I raved incessantly concerning',
'At point I interrupted meditations remark fact little fellow Chantilly better Théâtre des Variétés "',
'" But Lionel drift noble friend ; drift unknown apparent',
'Wilcox I sure heard cult casual way soon forgotten amidst mass equally weird reading imagining',
'" How far mus massa ? " inquired Jupiter',
'People heard queerest kind sounds',
'He died debt little property seized immediately creditors',
'\' Tiz de troof dat iz eberry vord ob "',
'We passed rapidly ; sun hot sheltered rays kind canopy enjoyed beauty scene lake saw Mont Saleve pleasant banks Montalegre distance surmounting beautiful Mont Blanc assemblage snowy mountains vain endeavour emulate ; coasting opposite banks saw mighty Jura opposing dark ambition quit native country insurmountable barrier invader wish enslave',
'I took merit',
'This speech troubled',
'Swiftly I thought Yes I witness scene drama',
'Alas companion I precipitated fall',
'After lovers joined supped alcove',
'At precisely carriage drew door principal inn',
'There primness stiffness carriage degree measured I express rectangular precision attending movement observed diminutive figure little savor world affectation pomposity constraint noticed gentleman undoubted dimensions readily placed account reserve hauteur commendable sense short dignity colossal proportion',
'Cries horror filled place endeavoured effect escape minutes market place cleared corpse lay ground ; maniac subdued exhausted sat leaning gaunt cheek thin hand',
'She urged old story decorum bug bear deters bliss opportunity bliss forever gone',
'" Indeed I dare die',
'I glanced sea',
'Seizing green jade object gave glance bleached cavern eyed face owner closed grave found',
'Then knew past merge old things day day thought hills north haunted Arkham rushing Miskatonic lonely rustic homestead people lay',
'But questioned Slater relapsed habitual vacancy mountaineer reiterated said preceding day',
'Many times afterward I saw moon beckon',
'Let survey appearances',
'It taken inconceivable rapidity character gigantic mantle rare flame extending horizon horizon',
'The action I present taking',
"But fluctuations shook depths soul sensitive youth ; longer deemed world subject possessed Evadne 's love ; felt nerve dire storms mental universe attack fragile quivered expectation advent",
'" Many persons neighbors gave evidence effect',
'And having arranged glasses ordinary form spectacles I applied gingerly proper position ; Madame Simpson adjusting cap folding arms sat bolt upright chair somewhat stiff prim somewhat undignified position',
'But tumult suddenly violent compulsory exertion diverted attention glare ruddy light thrown flaming stables windows apartment',
"Her views regard children placed words actions relative restraint Evadne plaything way fear ; talents vivacity slight alleviations monotony Countess 's life",
"He got communication Dr. Houghton Aylesbury attended Old Whateley illness found ponder grandfather 's words quoted physician",
'War revolution raging seas ; dynasty collapsed degenerate subjects flocking dubious intent Western Land',
'He awake calling mother grandfather graves quarter century',
'" More space Willy space soon',
'The reproaches agony extorted ; worse cureless uncomplaining depression mind sunk torpor painful silent moveless',
'In nervousness I looked discovered bolt clothes press size judging marks door',
"Our prime festivals held Perdita 's cottage ; weary talking past dreaming future",
'I listened quietly paused pour misery expressions shewed far deep wounds cure',
'That night youth beauty died elder world',
'Presently people simply villagers apparently farthest lead saw stood paralysed',
'Among better natures anguish dread fear eternal separation awful wonder produced unprecedented calamity drew closer ties kindred friendship',
'After hour got better control saw far city',
'I deceived ; I talked remaining months ; anxiety reach Windsor left reproach contention I pursued plan',
'It money partially necessaries life scarce',
'" Presently countrymen passed pausing near cottage entered conversation violent gesticulations ; I understand said spoke language country differed protectors',
'Upon exhibition ether revived rapidly restored health society friends knowledge resuscitation withheld relapse longer apprehended',
'" It kind force n\'t belong space ; kind force acts grows shapes laws sort Nature',
'I gazed fortifications impediments human beings entering citadel nature rashly ignorantly I repined',
'He uncouth man deeply imbued secrets science',
'Great pains taken scenery semblance reality impossible',
'Darkness fell stricken countryside passive organise real defence',
'This evident egregious unpardonable conceivable tricks whimsicalities buffooneries brought directly plainly intermediate agency connivance',
"Ef dew 'll singin ' ' laffin ' till break o ' day",
'There certain bulk space accounted cabinet',
'I endeavored shriek ; lips parched tongue moved convulsively attempt voice issued cavernous lungs oppressed weight incumbent mountain gasped palpitated heart elaborate struggling inspiration',
'Accordingly I kept north Main Martin turning inland crossing Federal Street safely north Green entering decayed patrician neighbourhood northern Broad Washington Lafayette Adams Streets',
'M. Valdemar resided principally Harlaem N.Y. year particularly noticeable extreme spareness person lower limbs resembling John Randolph ; whiteness whiskers violent contrast blackness hair consequence generally mistaken wig',
'The country people neighborhood visitors coming establishment given alarm "',
'But toilsome journey water fears redouble',
"Do n't worry wo n't hurt",
'The afternoon search brought light dusk came I stood Maple Hill looking hamlet valley Tempest Mountain',
'No Protector',
'And poring forbidden pages I felt forbidden spirit enkindling Morella place cold hand rake ashes dead philosophy low singular words strange meaning burned memory',
'But disordered fancy idea assumed daring character trespassed certain conditions kingdom inorganization',
'The change happened whilst I slept',
'I deliberation consigned article dignified pages " Lollipop " awaited event anxiety resignation',
'To handled care "',
'existing moon',
'My friend wrought I suspected touch harmless theatricalism started neurotically away actually cried sort gulping gasp released strain previous repression',
'As night came breath wind died away entire calm impossible conceive',
'I months prison I weak continual danger relapse I obliged travel nearly miles country town court held',
'As " Oppodeldoc " I began experience compassion poor fellow',
"There Bibulus O'Bumper",
'Once I witnessed scene singular interest theatres nature overpowered art overflowing cataract tear away puny manufacture mock cascade fed small portion waters',
"By time uneasy thoughts laid fair cheek pillow mother 's servant brought draught ; suspicion crossed novel proceeding sufficiently alarming determine potion ; dislike contention wish discover foundation conjectures said instinctively contradiction usual frankness pretend swallow medicine",
'Ye gods I behold departed spirit shade ghost beloved puppy I perceive sitting grace melancholy corner ?',
'By degrees Evadne related friend story stain received Greece weight sin accrued death husband',
'Besides suspended roof tomb large bell rope designed extend hole coffin fastened hands corpse',
'All confusion despair effort lighten ship throwing overboard cargo reached cutting away masts remained',
'He introduce wife courtesy devolving force sister Marian sweet intelligent girl hurried words acquainted',
'From youth I said I virtuous ; I dedicate life good ; I best extirpate evil spirit protects ill influence circumstances I suffer endeavour hope hope success cheerfully I gird task',
'It vast undulating plain covered seaweed strown shells small molluscs',
'I little expected enlightened scientific age find disciple Albertus Magnus Paracelsus',
'Believing I prodigious height far accursed branches wood I dragged floor fumbled windows I look time sky moon stars I read',
'It noticeable popular prejudices vulgar errors regard pestilences wars errors wo nt prevail appearance comet altogether unknown',
'It related acute respects oddly afflicted monomania building ancient Amriccan denominated " churches " kind pagoda instituted worship idols went names Wealth Fashion',
'The mere presence idea irresistible proof fact',
"Maounds o ' dead ' dyin '",
'She submissive held authority perpetual cloud dwelt brow ; looked expected enmity approached actions instigated feeling',
'No incidents hitherto befallen figure letter',
'Its approach seemingly rapid ; appearance unusual character',
'Here encircling tree passed little north east leaving tulip tree feet south making decided alteration course came near midway eastern western boundaries valley',
'This winter passed miserably tortured I anxious suspense ; I hope peace countenance find heart totally void comfort tranquillity',
'Oh There fearful chasm ; I adjure beware " " Ah dearest friend " I cried " fear Speak word ; bring peace death',
'It night like I shocked community queer conceit burial rich celebrated Squire Brewster maker local history interred slate headstone bearing graven skull crossbones slowly crumbling powder',
'What police extract came mainly immensely aged mestizo named Castro claimed sailed strange ports talked undying leaders cult mountains China',
'It youthful reverie filled speculations sort I arose afternoon winter state psychopathic institution I served interne brought man case haunted unceasingly',
'The living man clutching horrible stone idol unknown origin foot height nature authorities Sydney University Royal Society Museum College Street profess complete bafflement survivor says found cabin yacht small carved shrine common pattern',
'Have drunk intoxicating draught ?',
"I knew years age success guessing game ' odd ' attracted universal admiration",
'He man immense height probably feet stooping shoulders belied fact',
'With apparent calmness discussed probable spot found planned means use purpose',
'I formed habit listening intently slightly open portal choosing favourite hours midnight stillness odd vigil',
'Prompted preserving instinct self defence I broke spell hitherto held immovable flung dying torch creature menaced existence',
'Then night red fattened Romnod snorted heavily amidst poppied silks banquet couch died writhing whilst Iranon pale slender sang far corner',
'The mansion gone century reared stately height raptured vision ; window ablaze splendour candles',
'When I entered room I shut door',
'Now baying dead fleshless monstrosity grows louder louder stealthy whirring flapping accursed web wings circles closer closer I shall seek revolver oblivion refuge unnamed unnamable',
'But voyager quits vessel borne far descends light canoe ivory stained arabesque devices vivid scarlet',
'His chief amusements gunning fishing sauntering beach myrtles quest shells entomological specimens ; collection envied Swammerdamm',
'Elwood late night Gilman waited',
'I pledge honor gentleman Frenchman intend injury',
'I journied day ; moment misery encreased fever blood intolerable',
'At recur past personal occurrences',
'Yet unlike early life I confined Nature books',
'Let pause observe complexion man dark swarthy ; common swarthiness constituted sole point remembrance regards Valence Madame Deluc',
'We know meant " damning faint praise " hand fail seeing covert purpose " Daddy " glorifying feeble abuse ?',
'At times like minute circumstances assume giant majestic proportions ; swinging open white gate admitted forest arrested thoughts matter interest ; day act occur The setting crescent moon glittered massy trees right entered park scared troop deer fled bounding away forest shades',
'The officers satisfied',
'No guilt mischief malignity misery found comparable',
'Swarthy sinister strangers find faces like fashioned The Street moulded spirit',
'The intense life quickened pulses animated frame effect drawing mazes active life exalting lowliness bestowing majestic proportions insignificant objects I lived life peasant way trifling occupations swelled important pursuits ; affections impetuous engrossing passions nature changes invested divine attributes',
'He grew composed demeanor ; original air enthusiasm disappeared',
'Not monstrosity color wanting ; sunlight came chasm tinted orange purple ; vivid green grass valley reflected objects curtain vapor hung overhead loth total departure scene enchantingly beautiful',
'His friends remembered brilliant vision return',
'" There truth " said I " man acts theory',
'Even music wanting banners floated air shrill fife loud trumpet breathed forth sounds encouragement victory',
'I heard clock strike striking clock morbid fancy found new starting point idle wanderings',
'I awoke red madness mockery diabolism farther farther inconceivable vistas phobic crystalline anguish retreated reverberated',
'I struggled I gasped I died',
'There sufficient presence mind supposed remove corpse ; positive evidence corpse features quickly obliterated decay allowed lie conspicuously scene outrage I allude handkerchief deceased',
"We prepared view second elopement know elopement taken place indicating renewal betrayer 's advances result new proposals second individual prepared regard ' making ' old amour commencement new",
'To extent laws sanity apply case ?',
"Morning morning lie cliffs look world 's rim cryptical aether listening spectral bells wild cries gulls",
"Briden 's death reveals apparent cause probably excitement exposure",
'On Monday ascertained girl Rue des Drômes ; day elapsed tidings tardy search instituted points city environs',
'She evidently lady breeding',
'The fear old tradition neighbouring villages ; prime topic simple discourse poor mongrels leave valleys trade hand woven baskets primitive necessities shoot raise',
"A vulgar man 's deep",
"The question longer I share Adrian 's toils danger ; manner I Windsor neighbourhood imitate prudence zeal government produced order plenty London pestilence spread widely I secure health family",
'" If point requiring reflection " observed Dupin forebore enkindle wick " shall examine better purpose dark "',
'Penniless end supply drug makes life endurable I bear torture longer ; shall cast garret window squalid street',
'I time thankfully certain railway patrolled',
"It good theory n't indefinitely",
'The physical state man soon yield beatitude angels ; disease banished ; labour lightened heaviest burden',
"C Fletcher 's comedy Captain",
'The mansion fine I believe furnished good taste',
'For fine arts especially belles lettres entertained profound contempt',
"He volution corpse hitch embarrassed reflection ' torn ' garment",
'Thus appeared initiated mysteries life society knowledge deeper kind laid firmer foundations ; beauty sweetness fascinated understanding held thrall',
'The genius enlightened countenance united expression benevolence gave divine perfection beauty',
"Mr. Garrick obtain'd Admittance Difficulty ; Doctor notwithstanding great Friendship affecting decry Stage Things connected",
'It point came knocking door ; ancient door nail studded oak lay abyss white cloud',
'I choose current I find currents I tolerable headway propeller',
'The heat intolerable',
'The immense mountains precipices overhung sound river raging rocks dashing waterfalls spoke power mighty Omnipotence I ceased fear bend almighty created ruled elements displayed terrific guise',
'I arose argued trifles high key violent gesticulations ; noise steadily increased',
'In fact having satisfied egress quarter naturally bestow cursory examination',
"Why bring torture tempt kill Much happier frantic curiosity tore heart breast tried read secrets life 's blood dropping",
'In subsequent decades new inventions new names new events appeared book history people recall wonderingly Carter years let fall careless word undoubted connexion far future',
'They abounded ultra German opinions respecting duello',
'Two small boys sons Madame Deluc roaming woods near Barrière du Roule chanced penetrate close thicket large stones forming kind seat footstool',
'The windows room firmly fastened',
'\' By language stranger I suppose countryman ; French ? \' " \' No ; I educated French family understand language',
'There came period people curious steal count herd grazed precariously steep hillside old farmhouse find anaemic bloodless looking specimens',
'" Your opinions allow Baron von Jung main correct nice points discreditable university member',
'A poet having unusual pecuniary resources retaining necessary idea art culture author expresses interest imbue designs extent novelty beauty convey sentiment spiritual interference',
'Her voice grew gentle grew low I wish dwell wild meaning quietly uttered words',
"From feeling cunning blindly exercised officious malignant messenger speak Evadne 's illness ; garrulously gave account Raymond 's frequent visits adding narration circumstances convinced Perdita truth exaggerated unkindness perfidy Raymond",
'But moon went west tide ebbed sullen shore I saw light old spires waves uncovered white columns gay festoons green seaweed',
'It impossibility normal world',
'I doubted care fidelity dearest friends',
'The district contained appeared abode kindly spirit',
"Had possible adduce instead examples bodies found floating end days examples properly regarded exceptions L'Etoile 's rule time rule confuted",
'Could I face face intellectual emanations explain mystery I learn discover read ?',
'No flowers lifted dew laden cups meet dawn ; dry grass withered plains ; burning fields air vacant birds ; cicale children sun began shrill deafening song cypresses olives',
'loved ; notwithstanding disappointment quelled passion ambition held strong combat',
'From directions distance I hear sound hoarse voices footsteps curious kind pattering sound like footsteps',
'I felt palpable invisible object passed lightly person ; I saw lay golden carpet middle rich lustre thrown censer shadow faint indefinite shadow angelic aspect fancied shadow shade',
'" I awaiting " continued looking door apartment " I awaiting person perpetrator butcheries measure implicated perpetration',
'But treasure world hold threat vengeance hold power urge return lonely murderer toilsome perilous path thicket blood chilling recollections ?',
'We forgot Malcolm Macduff mere human beings acted simple passions warmed breasts',
'The resources mind occasion truly astonishing conversation imagination ; imitation Persian Arabic writers invented tales wonderful fancy passion',
'Their splendor dazzled enlightened',
'He repeated movement grotesque',
'But friend greater danger I fear I felt vague resentment deem capable deserting circumstances',
'The grocery boy prepared reality left bewildered disturbed',
'Excavation easier I expected point I encountered queer interruption ; lean vulture darted cold sky pecked frantically grave earth I killed blow spade',
'The days followed pain ; I regretted I yielded haughty lady watched motions turned beloved task nursing friend work pain irritation',
'Whether come I',
'Something feel motors belong realm seeking left car edge forest putting great key coat pocket walked hill',
'This I spot review original " Oil Bob " occupying thirty pages " Lollipop "',
'Poor John His Son fared better I think Baronet',
'They variation principle investigations ; best urged unusual emergency extraordinary reward extend exaggerate old modes practice touching principles',
'You came embodied image fondest dreams',
'A grin face monster ; jeer fiendish finger pointed corpse wife',
'This condition things long existed',
'From blurred fragmentary memories infer prove little',
'It exceedingly difficult speculate prospectively consequences discovery thing positively maintained announcement discovery months ago material influence regard settlement California',
'With sentiments profound respect Your obedient servant VON JUNG',
'It portrait young girl ripening womanhood',
"The eulogies Mr. Crab editor 's means fulsomely indiscriminate",
'I inclined opinion',
'She studiously shut prospect future cradled heart present blessings',
'From time new spirit life animated decaying frame stranger',
'So endless twilights I dreamed waited I knew I waited',
'Sights woe familiar I tell anguish pain I witnessed despairing moans age terrible smiles infancy bosom horror reader limbs quivering hair end wonder I seized sudden frenzy dash precipice close eyes sad end world',
'He notes variation face play progresses gathering fund thought differences expression certainty surprise triumph chagrin',
'He good morning stayed away classes',
'" \' We suppose \' said miser \' symptoms ; doctor directed ? \' " \' Take \' said Abernethy \' advice sure \' "',
'" Well Bobby boy \'re fine fellow n\'t ?',
'I recall distinctly began months ago',
'" And window panes ? " " They gone',
"When seasons equal air breeds disorders surface longer liable blights droughts sickness cease ; men 's passions dead poverty depart",
'" Glad ye nigh haouse en \' d sense ta come right',
'He fired crowd women children',
'They fuller fullest gazelle eyes tribe valley Nourjahad',
'After feeling pulse applying mirror lips requested speak sleep waker',
'The customs world conventional follies',
'By time pulse imperceptible breathing stertorous intervals half minute',
'Pareamo aver qui tutto il ben raccolto Che fra mortali piu parte si rimembra',
'By means ignorant men I found little difficulty gaining purpose',
'Almost dazed sudden obstacle violently dreading fall night decaying half unlighted town I left bus reëntered hotel lobby ; sullen queer looking night clerk told I Room floor large running water dollar',
'D Vienna evil turn I told good humoredly I remember',
'He proceeded observing analyzing classifying facts instantiae naturae affectedly called general laws',
'I visited frequently boyhood',
'In brooding fire autumn Carter took old remembered way past graceful lines rolling hill stone walled meadow distant vale hanging woodland curving road nestling farmstead crystal windings Miskatonic crossed rustic bridges wood stone',
'But comprehend',
'Soon completion exhibited Presburg Paris Vienna continental cities',
'He civil cordial manner I intent observing arrangements dwelling interested personal appearance tenant',
'For example known open drawer opens main compartment closing door cupboard No opens main compartment pulling drawer shuts drawer shutting main compartment opens door cupboard No main compartment open game chess commenced machine closed',
'For short space time I remained window watching pallid lightnings played Mont Blanc listening rushing Arve pursued noisy way beneath',
'Ye Gods sigh It sunk heart',
"Neither man 's death needed consummate series accomplish requires",
'" Be " said seventh',
'His wife assured observed difference absence children study infinite surprise complained unaccustomed quiet',
'It I said nineteenth October ; autumn far advanced dreary',
'His rank merit ?',
"Even De L'Omelette pronounced bien comme il faut",
'They arouse slumber I wide awake I screamed restored possession memory',
'They acquired new unlimited powers ; command thunders heaven mimic earthquake mock invisible world shadows "',
'When conversed manner cold constrained ; eyes speak turned black lustre expressed living sadness',
'" She arrived safety town leagues cottage De Lacey attendant fell dangerously ill',
'" Fine writer " said Edinburgh',
'She looked hand writing mistake repeated words " Do I charge I entreat permit guests wonder absence " old crone going talk filled ear strange medley truth falsehood',
'This picture hellish image ; train ideas started mind Here new treasuries data Cthulhu Cult evidence strange interests sea land',
'Especially apprehensive concerning mind impulses creature space following death delicate cerebral cells suffered deterioration',
'Thus poor sufferer tried comfort',
"' A piece ' says journal ' unfortunate girl 's petticoats torn tied chin head probably prevent screams",
'" And rescued strange perilous situation ; benevolently restored life "',
'" While I listened extremity astonishment I need attempt describe strong brief gust wind bore incumbent fog wand enchanter',
'The position stars guide',
'I dare like peep divinity temple',
'For people Ulthar simple knew cats came',
'And I mentioned provinces common understanding poetic sentiment declared capable expatiating',
'When doors shut dwarf enabled bring body box noise produced portion machinery allowing unheard close door entered',
'But Perdita ?',
'At noon lunched University Spa picking paper seat waited dessert',
"Gilman dropped doctor 's office th month surprised find temperature high feared",
'I heard difference sexes birth growth children father doted smiles infant lively sallies older child life cares mother wrapped precious charge mind youth expanded gained knowledge brother sister relationships bind human mutual bonds',
'There moonlight flooded spacious plain spectacle mortal having seen forget',
'" You " I asked " remain Greece ? " " Assuredly " replied Raymond',
'Nor shall friend ; cheer ; cease weep I entreat',
'I started beheld radiant form rise trees',
'This I earnestly entreat I know comply "',
'Thus far I faithfully said',
'Somebody accosted street mistaking personage Doctor Dubble L. Dee lecturer quack physics',
'For example I bought pen ink paper furious activity',
'Brevet Brigadier General John A. B. C. Smith man man',
'When question demanded explicitly Maelzel " Is Automaton pure machine ? " reply invariably " I "',
'I wish ; tall age sweet laughing blue eyes dark eyelashes curling hair',
'The corpse greatly decayed clotted gore stood erect eyes spectators',
'His eyes looking past malodorous sea positively starting head ; face mask fear worthy Greek tragedy',
'The chanting men Arkham unmistakable Wheeler saw glass raising arms rhythmic incantation',
'I paused breath ; meantime accident occurred momentous nature moral metaphysical point view passed notice',
'The diddler flies assistance giving friend comfortable thrashing insists attending lady door',
'And thing epoch given result afforded numberless comets example presented inspection difficulty determining analytic retrogradation original impulse',
'I confess I entertained feeble hope final deliverance I saw lash box commit sea " " They sank matter course " replied captain " like shot',
'" You wrong " replied fiend ; " instead threatening I content reason',
'Saying seated small table pen ink paper',
'While musing singularity fate I unwittingly daubed tar brush edges neatly folded studding sail lay near barrel',
'But house quaint old building veritably palace enchantment There end windings incomprehensible subdivisions',
'IT quiet afternoon I strolled forth goodly city Edina',
'Was Fate preserving reason draw irresistibly end horrible unthinkable man dreamed ?',
'An omnibus driver Valence testified saw Marie Rogêt cross ferry Seine Sunday question company young man dark complexion',
'Hey ? Heh heh heh heh',
'Only old Zebulon group justice situation suggested plausible explanation',
'If dishonour I conceive dishonour come near I lost "',
'The man shivered read scroll Carter shivered',
'Here finds odd things people enjoy extreme happiness ; law ; die pain ; thirty feet height ; live thousand years ; emperor called Irdonozur ; jump feet high gravitating influence fly fans',
'Alas safe convicted crime ?',
'He closes door locks coming round opens drawer extent',
'This picture gone doubtless temptation urged murderer deed',
'It remarkable character I seen frequently property family physician ; came table I shudder ?',
'" Ugh ugh ugh " chuckled Tarpaulin heeding general excitation " ugh ugh ugh ugh ugh ugh ugh ugh ugh I saying " said " I saying Mr. King Pest poked marlin spike matter gallons Black Strap trifle tight sea boat like overstowed comes drinking health Devil God assoilzie going marrow bones ill favored majesty I know I know sinner world Tim Hurlygurly stage player \'s guess sort thing utterly altogether past comprehension "',
'This benefit fully repaid ; Justine grateful little creature world I mean professions I heard pass lips eyes adored protectress',
'Yet I dead appear ministers vengeance conduct swear shall live swear shall triumph accumulated woes survive add list dark crimes',
'He detained days longer hastened',
'Sometimes lone poet traveller come view try picture vanished glory ; travellers poets',
'Hieroglyphics covered walls pillars undetermined point come voice voice ; chaotic sensation fancy transmute sound attempted render unpronounceable jumble letters " Cthulhu fhtagn "',
'Opposite door lady whit extraordinary character',
'I sagacity discover unnatural hideousness person chief object horror beheld',
'" He married " said " love love ; bride far worthy love "',
'I lived temple glorified intensest sense devotion rapture ; I walked consecrated contemplating power excellence ; For O stood like youth Transformed real dream Cloathing palpable familiar With golden exhalations dawn',
'This gate inserted lofty wall ; appears cross river right angles',
'The gruff voice Frenchman',
'Here difficult perceive intention reasoner',
'The " little cliff " edge carelessly thrown rest weightier portion body hung kept falling tenure elbow extreme slippery edge " little cliff " arose sheer unobstructed precipice black shining rock sixteen feet world crags beneath',
'Many things taught secretiveness need exert pressure',
'But appearance father like good angel I gradually recovered health',
'Had I right benefit inflict curse everlasting generations ?',
"Old Kranon burgomaster swore dark folk taken cats away revenge killing Menes ' kitten ; cursed caravan little boy",
'I marry reigning sovereign I sure heart free',
'Therefore instead trying door I knocked feeling I trepidation I scarcely explain',
'Shaken mental revolution I known I resolved visit Mate Johansen Oslo',
'I count sheer speed chance getting window hostile forces coördinated open right door pass key',
'I took thee rose wood coffin inlaid ivory',
'She disdain interference',
'The season May weather stormless ; promised prosperous voyage',
'All movements arm right angles',
'Our circle small bound close ties affection mutual misfortune',
'We equal ; near hand equality levelling state beauty strength wisdom vain riches birth',
'At length opened eyes ; breathed difficulty unable speak',
'Why lose added years prudence pledge marriage gave country ought encrease diminish claims confidence ?',
'Meeting betrothed avenue thronged élite city I hastening greet best considered bows small particle foreign matter lodging corner eye rendered moment completely blind',
'Erring mortals forced rigid code seek concealment ; came use taste concealed',
"The Earl Ross 's telescope lately constructed England speculum reflecting surface square inches ; Herschel telescope having",
'Medical aid easily procured food difficult obtain human beings unwithheld shame unbeheld fellows ventured deeds greater wickedness gave way readily abject fears',
...]
In [38]:
xtrain = np.array(x_train_fltr_join)
xvalid = np.array(x_valid_fltr_join)
In [39]:
xtrain.shape,xvalid.shape,y_train.shape,y_valid.shape
Out[39]:
((9789,), (9790,), (9789,), (9790,))
In [8]:
from spacy.vectors import Vectors
import spacy
nlp = spacy.load('en')
#nlp.vocab.vectors.from_glove('data/glove.840B.300d.txt')
In [ ]:
xtrain_token=[]
for i in x_train:
doc = nlp(i)
xtrain_token.append([token.text for token in doc ])
In [ ]:
xvalid_token=[]
for i in x_valid:
doc = nlp(i)
xvalid_token.append([token.text for token in doc ])
In [11]:
loc = "data/"
import bcolz
import pickle
import sys
import pdb
import os
from tensorflow.contrib.learn.python import preprocessing
In [40]:
p = preprocessing.text.VocabularyProcessor(max_document_length=500)
xtrain_ids = np.array(list(p.fit_transform(x_train_fltr_join)))
xvalid_ids = np.array(list(p.fit_transform(x_valid_fltr_join)))
In [41]:
xtrain_ids.shape,xvalid_ids.shape
Out[41]:
((9789, 500), (9790, 500))
In [43]:
xtrain_ids_v[np.where(xtrain_ids_v > 21000)].size
Out[43]:
0
In [8]:
vocab_size = 21000
In [10]:
xtrain_ids_v = np.array([[i if i<vocab_size else vocab_size-1 for i in s] for s in xtrain_ids])
xvalid_ids_v = np.array([[i if i<vocab_size else vocab_size-1 for i in s] for s in xvalid_ids])
---------------------------------------------------------------------------
NameError Traceback (most recent call last)
<ipython-input-10-cd9e3f3dc19d> in <module>()
----> 1 xtrain_ids_v = np.array([[i if i<vocab_size else vocab_size-1 for i in s] for s in xtrain_ids])
2 xvalid_ids_v = np.array([[i if i<vocab_size else vocab_size-1 for i in s] for s in xvalid_ids])
NameError: name 'xtrain_ids' is not defined
In [20]:
vocab_size = 21000
seq_len = 500
In [14]:
import pickle
In [ ]:
file1 = open("predict_author_input.pkl","wb")
pickle.dump([xtrain_ids_v,xvalid_ids_v,ytrain_enc,yvalid_enc],file1)
In [ ]:
In [15]:
xt,xv,yt,yv = pickle.load(open("predict_author_input.pkl","rb"))
In [ ]:
from spacy.vectors import Vectors
In [45]:
# we need to binarize the labels for the neural net
ytrain_enc = np_utils.to_categorical(y_train)
yvalid_enc = np_utils.to_categorical(y_valid)
In [18]:
from sklearn import preprocessing as skp
scl = skp.StandardScaler()
xtrain_ids_scl = scl.fit_transform(xtrain_ids_v)
xvalid_ids_scl = scl.transform(xvalid_ids_v)
/home/surya/DL/lib/python3.5/site-packages/sklearn/utils/validation.py:475: DataConversionWarning: Data with input dtype int64 was converted to float64 by StandardScaler.
warnings.warn(msg, DataConversionWarning)
In [16]:
from keras.layers import Conv1D
In [52]:
model = Sequential([
Embedding(vocab_size, 100, input_length=seq_len),
Dropout(0.25),
Conv1D(padding="same", kernel_size=3, filters=64, activation="relu"),
Dropout(0.25),
MaxPooling1D(),
Flatten(),
#Dense(1024,activation='relu'),
Dense(100, activation='relu'),
Dropout(0.7),
Dense(3, activation='softmax')])
In [53]:
model.compile(loss='categorical_crossentropy', optimizer="adam", metrics=['accuracy'])
#earlystop = EarlyStopping(monitor='val_loss', min_delta=0, patience=3, verbose=0, mode='auto')
In [55]:
model.optimizer.lr=0.1
In [57]:
model.fit(xt,yt,batch_size=64,epochs=5,
validation_data=(xv,yv))
#model.save_weights('model1_weights.h5')
Train on 9789 samples, validate on 9790 samples
Epoch 1/5
9789/9789 [==============================] - 86s 9ms/step - loss: 0.0804 - acc: 0.9751 - val_loss: 1.0751 - val_acc: 0.7492
Epoch 2/5
9789/9789 [==============================] - 86s 9ms/step - loss: 0.0622 - acc: 0.9810 - val_loss: 1.1662 - val_acc: 0.7532
Epoch 3/5
9789/9789 [==============================] - 86s 9ms/step - loss: 0.0439 - acc: 0.9871 - val_loss: 1.2459 - val_acc: 0.7561
Epoch 4/5
9789/9789 [==============================] - 86s 9ms/step - loss: 0.0269 - acc: 0.9915 - val_loss: 1.4562 - val_acc: 0.7587
Epoch 5/5
9789/9789 [==============================] - 87s 9ms/step - loss: 0.0309 - acc: 0.9910 - val_loss: 1.3910 - val_acc: 0.7546
Out[57]:
<keras.callbacks.History at 0x7f2b73d63a90>
In [ ]:
model.save_weights('model1_best.h5')
In [37]:
model_bn = Sequential([
Embedding(vocab_size, 300, input_length=seq_len,
trainable=True),
BatchNormalization(),
Dropout(0.25),
Conv1D(padding="same", kernel_size=5, filters=64, activation="relu"),
BatchNormalization(),
Dropout(0.25),
MaxPooling1D(),
Flatten(),
Dense(100, activation='relu'),
BatchNormalization(),
Dropout(0.5),
Dense(3, activation='softmax')])
model_bn.compile(loss='categorical_crossentropy', optimizer="adam", metrics=['accuracy'])
In [38]:
model_bn.fit(xtrain_ids_v,ytrain_enc,batch_size=256,epochs=10,
validation_data=(xvalid_ids_v,yvalid_enc))
Train on 9789 samples, validate on 9790 samples
Epoch 1/10
9789/9789 [==============================] - 88s 9ms/step - loss: 1.4586 - acc: 0.3753 - val_loss: 1.1250 - val_acc: 0.4101
Epoch 2/10
9789/9789 [==============================] - 87s 9ms/step - loss: 1.0405 - acc: 0.5275 - val_loss: 1.2078 - val_acc: 0.4101
Epoch 3/10
9789/9789 [==============================] - 87s 9ms/step - loss: 0.5358 - acc: 0.7979 - val_loss: 1.2457 - val_acc: 0.4101
Epoch 4/10
9789/9789 [==============================] - 87s 9ms/step - loss: 0.2053 - acc: 0.9331 - val_loss: 1.2488 - val_acc: 0.4101
Epoch 5/10
9789/9789 [==============================] - 87s 9ms/step - loss: 0.1017 - acc: 0.9710 - val_loss: 1.2370 - val_acc: 0.4101
Epoch 6/10
9789/9789 [==============================] - 87s 9ms/step - loss: 0.0542 - acc: 0.9863 - val_loss: 1.3065 - val_acc: 0.4101
Epoch 7/10
9789/9789 [==============================] - 88s 9ms/step - loss: 0.0317 - acc: 0.9941 - val_loss: 1.3343 - val_acc: 0.4101
Epoch 8/10
9789/9789 [==============================] - 99s 10ms/step - loss: 0.0259 - acc: 0.9945 - val_loss: 1.8886 - val_acc: 0.4178
Epoch 9/10
9789/9789 [==============================] - 99s 10ms/step - loss: 0.0190 - acc: 0.9963 - val_loss: 1.7552 - val_acc: 0.5220
Epoch 10/10
9789/9789 [==============================] - 92s 9ms/step - loss: 0.0142 - acc: 0.9975 - val_loss: 2.7067 - val_acc: 0.5645
Out[38]:
<keras.callbacks.History at 0x7ffafe77d438>
In [16]:
model_l = Sequential()
model_l.add(Embedding(vocab_size,
300,
input_length=seq_len,
trainable=True))
model_l.add(SpatialDropout1D(0.3))
model_l.add(GRU(300, dropout=0.3, recurrent_dropout=0.3, return_sequences=True))
model_l.add(GRU(300, dropout=0.3, recurrent_dropout=0.3))
model_l.add(Dense(1024, activation='relu'))
model_l.add(Dropout(0.8))
model_l.add(Dense(1024, activation='relu'))
model_l.add(Dropout(0.8))
model_l.add(Dense(3))
model_l.add(Activation('softmax'))
model_l.compile(loss='categorical_crossentropy', optimizer='adam')
# Fit the model with early stopping callback
earlystop = EarlyStopping(monitor='val_loss', min_delta=0, patience=3, verbose=0, mode='auto')
model_l.fit(xtrain_ids_v, y=ytrain_enc, batch_size=512, epochs=10,
verbose=1, validation_data=(xvalid_ids_v, yvalid_enc), callbacks=[earlystop])
Train on 9789 samples, validate on 9790 samples
Epoch 1/10
---------------------------------------------------------------------------
ResourceExhaustedError Traceback (most recent call last)
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args)
1322 try:
-> 1323 return fn(*args)
1324 except errors.OpError as e:
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in _run_fn(session, feed_dict, fetch_list, target_list, options, run_metadata)
1301 feed_dict, fetch_list, target_list,
-> 1302 status, run_metadata)
1303
~/DL/lib/python3.5/site-packages/tensorflow/python/framework/errors_impl.py in __exit__(self, type_arg, value_arg, traceback_arg)
472 compat.as_text(c_api.TF_Message(self.status.status)),
--> 473 c_api.TF_GetCode(self.status.status))
474 # Delete the underlying status object from memory otherwise it stays alive
ResourceExhaustedError: OOM when allocating tensor with shape[512,500,300]
[[Node: gru_4/zeros_like = ZerosLike[T=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:GPU:0"](gru_3/transpose_1)]]
[[Node: loss_1/mul/_179 = _Recv[client_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_3975_loss_1/mul", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]()]]
During handling of the above exception, another exception occurred:
ResourceExhaustedError Traceback (most recent call last)
<ipython-input-16-c72c557640a6> in <module>()
21 earlystop = EarlyStopping(monitor='val_loss', min_delta=0, patience=3, verbose=0, mode='auto')
22 model_l.fit(xtrain_ids_v, y=ytrain_enc, batch_size=512, epochs=10,
---> 23 verbose=1, validation_data=(xvalid_ids_v, yvalid_enc), callbacks=[earlystop])
~/DL/lib/python3.5/site-packages/keras/models.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, **kwargs)
891 class_weight=class_weight,
892 sample_weight=sample_weight,
--> 893 initial_epoch=initial_epoch)
894
895 def evaluate(self, x, y, batch_size=32, verbose=1,
~/DL/lib/python3.5/site-packages/keras/engine/training.py in fit(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, **kwargs)
1629 initial_epoch=initial_epoch,
1630 steps_per_epoch=steps_per_epoch,
-> 1631 validation_steps=validation_steps)
1632
1633 def evaluate(self, x=None, y=None,
~/DL/lib/python3.5/site-packages/keras/engine/training.py in _fit_loop(self, f, ins, out_labels, batch_size, epochs, verbose, callbacks, val_f, val_ins, shuffle, callback_metrics, initial_epoch, steps_per_epoch, validation_steps)
1211 batch_logs['size'] = len(batch_ids)
1212 callbacks.on_batch_begin(batch_index, batch_logs)
-> 1213 outs = f(ins_batch)
1214 if not isinstance(outs, list):
1215 outs = [outs]
~/DL/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py in __call__(self, inputs)
2330 updated = session.run(self.outputs + [self.updates_op],
2331 feed_dict=feed_dict,
-> 2332 **self.session_kwargs)
2333 return updated[:len(self.outputs)]
2334
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in run(self, fetches, feed_dict, options, run_metadata)
887 try:
888 result = self._run(None, fetches, feed_dict, options_ptr,
--> 889 run_metadata_ptr)
890 if run_metadata:
891 proto_data = tf_session.TF_GetBuffer(run_metadata_ptr)
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in _run(self, handle, fetches, feed_dict, options, run_metadata)
1118 if final_fetches or final_targets or (handle and feed_dict_tensor):
1119 results = self._do_run(handle, final_targets, final_fetches,
-> 1120 feed_dict_tensor, options, run_metadata)
1121 else:
1122 results = []
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in _do_run(self, handle, target_list, fetch_list, feed_dict, options, run_metadata)
1315 if handle is None:
1316 return self._do_call(_run_fn, self._session, feeds, fetches, targets,
-> 1317 options, run_metadata)
1318 else:
1319 return self._do_call(_prun_fn, self._session, handle, feeds, fetches)
~/DL/lib/python3.5/site-packages/tensorflow/python/client/session.py in _do_call(self, fn, *args)
1334 except KeyError:
1335 pass
-> 1336 raise type(e)(node_def, op, message)
1337
1338 def _extend_graph(self):
ResourceExhaustedError: OOM when allocating tensor with shape[512,500,300]
[[Node: gru_4/zeros_like = ZerosLike[T=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:GPU:0"](gru_3/transpose_1)]]
[[Node: loss_1/mul/_179 = _Recv[client_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_3975_loss_1/mul", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]()]]
Caused by op 'gru_4/zeros_like', defined at:
File "/usr/lib/python3.5/runpy.py", line 184, in _run_module_as_main
"__main__", mod_spec)
File "/usr/lib/python3.5/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel_launcher.py", line 16, in <module>
app.launch_new_instance()
File "/home/surya/DL/lib/python3.5/site-packages/traitlets/config/application.py", line 658, in launch_instance
app.start()
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/kernelapp.py", line 477, in start
ioloop.IOLoop.instance().start()
File "/home/surya/DL/lib/python3.5/site-packages/zmq/eventloop/ioloop.py", line 177, in start
super(ZMQIOLoop, self).start()
File "/home/surya/DL/lib/python3.5/site-packages/tornado/ioloop.py", line 888, in start
handler_func(fd_obj, events)
File "/home/surya/DL/lib/python3.5/site-packages/tornado/stack_context.py", line 277, in null_wrapper
return fn(*args, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/zmq/eventloop/zmqstream.py", line 440, in _handle_events
self._handle_recv()
File "/home/surya/DL/lib/python3.5/site-packages/zmq/eventloop/zmqstream.py", line 472, in _handle_recv
self._run_callback(callback, msg)
File "/home/surya/DL/lib/python3.5/site-packages/zmq/eventloop/zmqstream.py", line 414, in _run_callback
callback(*args, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/tornado/stack_context.py", line 277, in null_wrapper
return fn(*args, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/kernelbase.py", line 283, in dispatcher
return self.dispatch_shell(stream, msg)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell
handler(stream, idents, msg)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/kernelbase.py", line 399, in execute_request
user_expressions, allow_stdin)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/ipkernel.py", line 196, in do_execute
res = shell.run_cell(code, store_history=store_history, silent=silent)
File "/home/surya/DL/lib/python3.5/site-packages/ipykernel/zmqshell.py", line 533, in run_cell
return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/IPython/core/interactiveshell.py", line 2728, in run_cell
interactivity=interactivity, compiler=compiler, result=result)
File "/home/surya/DL/lib/python3.5/site-packages/IPython/core/interactiveshell.py", line 2850, in run_ast_nodes
if self.run_code(code, result):
File "/home/surya/DL/lib/python3.5/site-packages/IPython/core/interactiveshell.py", line 2910, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "<ipython-input-16-c72c557640a6>", line 8, in <module>
model_l.add(GRU(300, dropout=0.3, recurrent_dropout=0.3))
File "/home/surya/DL/lib/python3.5/site-packages/keras/models.py", line 475, in add
output_tensor = layer(self.outputs[0])
File "/home/surya/DL/lib/python3.5/site-packages/keras/layers/recurrent.py", line 483, in __call__
return super(RNN, self).__call__(inputs, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/keras/engine/topology.py", line 603, in __call__
output = self.call(inputs, **kwargs)
File "/home/surya/DL/lib/python3.5/site-packages/keras/layers/recurrent.py", line 1508, in call
initial_state=initial_state)
File "/home/surya/DL/lib/python3.5/site-packages/keras/layers/recurrent.py", line 541, in call
initial_state = self.get_initial_state(inputs)
File "/home/surya/DL/lib/python3.5/site-packages/keras/layers/recurrent.py", line 469, in get_initial_state
initial_state = K.zeros_like(inputs) # (samples, timesteps, input_dim)
File "/home/surya/DL/lib/python3.5/site-packages/keras/backend/tensorflow_backend.py", line 753, in zeros_like
return tf.zeros_like(x, dtype=dtype, name=name)
File "/home/surya/DL/lib/python3.5/site-packages/tensorflow/python/ops/array_ops.py", line 1495, in zeros_like
return gen_array_ops._zeros_like(tensor, name=name)
File "/home/surya/DL/lib/python3.5/site-packages/tensorflow/python/ops/gen_array_ops.py", line 5960, in _zeros_like
"ZerosLike", x=x, name=name)
File "/home/surya/DL/lib/python3.5/site-packages/tensorflow/python/framework/op_def_library.py", line 787, in _apply_op_helper
op_def=op_def)
File "/home/surya/DL/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 2956, in create_op
op_def=op_def)
File "/home/surya/DL/lib/python3.5/site-packages/tensorflow/python/framework/ops.py", line 1470, in __init__
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access
ResourceExhaustedError (see above for traceback): OOM when allocating tensor with shape[512,500,300]
[[Node: gru_4/zeros_like = ZerosLike[T=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:GPU:0"](gru_3/transpose_1)]]
[[Node: loss_1/mul/_179 = _Recv[client_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_3975_loss_1/mul", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]()]]
In [50]:
# A simple bidirectional LSTM with glove embeddings and two dense layers
model2 = Sequential()
model2.add(Embedding(vocab_size,
64,
input_length=seq_len,
trainable=True))
model2.add(SpatialDropout1D(0.3))
model2.add(Bidirectional(LSTM(64, dropout=0.3, recurrent_dropout=0.3)))
model2.add(Dense(1024, activation='relu'))
model2.add(Dropout(0.8))
model2.add(Dense(1024, activation='relu'))
model2.add(Dropout(0.8))
model2.add(Dense(3))
model2.add(Activation('softmax'))
model2.compile(loss='categorical_crossentropy', optimizer='adam',metrics=['accuracy'])
# Fit the model with early stopping callback
earlystop = EarlyStopping(monitor='val_loss', min_delta=0, patience=3, verbose=0, mode='auto')
model2.fit(xt, y=yt, batch_size=512, epochs=10,
verbose=1, validation_data=(xv, yv), callbacks=[earlystop])
Train on 9789 samples, validate on 9790 samples
Epoch 1/10
9789/9789 [==============================] - 164s 17ms/step - loss: 1.0879 - acc: 0.3988 - val_loss: 1.0806 - val_acc: 0.4040
Epoch 2/10
9789/9789 [==============================] - 161s 16ms/step - loss: 1.0662 - acc: 0.4270 - val_loss: 1.0658 - val_acc: 0.4581
Epoch 3/10
9789/9789 [==============================] - 162s 17ms/step - loss: 0.9704 - acc: 0.5429 - val_loss: 0.9752 - val_acc: 0.5461
Epoch 4/10
9789/9789 [==============================] - 175s 18ms/step - loss: 0.8510 - acc: 0.6094 - val_loss: 0.9600 - val_acc: 0.5727
Epoch 5/10
9789/9789 [==============================] - 225s 23ms/step - loss: 0.7768 - acc: 0.6471 - val_loss: 0.9077 - val_acc: 0.6064
Epoch 6/10
9789/9789 [==============================] - 179s 18ms/step - loss: 0.6984 - acc: 0.7098 - val_loss: 0.8735 - val_acc: 0.6413
Epoch 7/10
9789/9789 [==============================] - 160s 16ms/step - loss: 0.6250 - acc: 0.7596 - val_loss: 0.8218 - val_acc: 0.6726
Epoch 8/10
9789/9789 [==============================] - 160s 16ms/step - loss: 0.5088 - acc: 0.8189 - val_loss: 0.9391 - val_acc: 0.6681
Epoch 9/10
9789/9789 [==============================] - 160s 16ms/step - loss: 0.5222 - acc: 0.8143 - val_loss: 0.8012 - val_acc: 0.6789
Epoch 10/10
9789/9789 [==============================] - 160s 16ms/step - loss: 0.4640 - acc: 0.8293 - val_loss: 0.7907 - val_acc: 0.6904
Out[50]:
<keras.callbacks.History at 0x7fbcb2575ac8>
In [51]:
model2.optimizer.lr=0.1
model2.fit(xt, y=yt, batch_size=512, epochs=3,
verbose=1, validation_data=(xv, yv), callbacks=[earlystop])
Train on 9789 samples, validate on 9790 samples
Epoch 1/3
9789/9789 [==============================] - 160s 16ms/step - loss: 0.4421 - acc: 0.8329 - val_loss: 0.7880 - val_acc: 0.6962
Epoch 2/3
9789/9789 [==============================] - 156s 16ms/step - loss: 0.4174 - acc: 0.8403 - val_loss: 0.7993 - val_acc: 0.7044
Epoch 3/3
9789/9789 [==============================] - 160s 16ms/step - loss: 0.3863 - acc: 0.8519 - val_loss: 0.8664 - val_acc: 0.6799
Out[51]:
<keras.callbacks.History at 0x7fbcb221bd30>
Content source: vbsteja/code
Similar notebooks: