mirror of
				https://github.com/deepset-ai/haystack.git
				synced 2025-11-04 03:39:31 +00:00 
			
		
		
		
	Fix Tutorial 9 (#734)
* Add package download * Change dev to train file
This commit is contained in:
		
							parent
							
								
									3331608e03
								
							
						
					
					
						commit
						8d47a71b00
					
				@ -8,7 +8,7 @@
 | 
				
			|||||||
    "[](https://colab.research.google.com/github/deepset-ai/haystack/blob/master/tutorials/Tutorial9_DPR_training.ipynb)\n",
 | 
					    "[](https://colab.research.google.com/github/deepset-ai/haystack/blob/master/tutorials/Tutorial9_DPR_training.ipynb)\n",
 | 
				
			||||||
    "\n",
 | 
					    "\n",
 | 
				
			||||||
    "Haystack contains all the tools needed to train your own Dense Passage Retrieval model.\n",
 | 
					    "Haystack contains all the tools needed to train your own Dense Passage Retrieval model.\n",
 | 
				
			||||||
    "This tutorial will guide you through the steps required to create a retriever that is specifically tailored to your domain.\n"
 | 
					    "This tutorial will guide you through the steps required to create a retriever that is specifically tailored to your domain."
 | 
				
			||||||
   ],
 | 
					   ],
 | 
				
			||||||
   "metadata": {
 | 
					   "metadata": {
 | 
				
			||||||
    "collapsed": false,
 | 
					    "collapsed": false,
 | 
				
			||||||
@ -17,6 +17,25 @@
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
   }
 | 
					   }
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
 | 
					  {
 | 
				
			||||||
 | 
					   "cell_type": "code",
 | 
				
			||||||
 | 
					   "execution_count": null,
 | 
				
			||||||
 | 
					   "outputs": [],
 | 
				
			||||||
 | 
					   "source": [
 | 
				
			||||||
 | 
					    "# Install the latest release of Haystack in your own environment\n",
 | 
				
			||||||
 | 
					    "#! pip install farm-haystack\n",
 | 
				
			||||||
 | 
					    "\n",
 | 
				
			||||||
 | 
					    "# Install the latest master of Haystack\n",
 | 
				
			||||||
 | 
					    "!pip install git+https://github.com/deepset-ai/haystack.git\n",
 | 
				
			||||||
 | 
					    "!pip install torch==1.6.0+cu101 torchvision==0.6.1+cu101 -f https://download.pytorch.org/whl/torch_stable.html"
 | 
				
			||||||
 | 
					   ],
 | 
				
			||||||
 | 
					   "metadata": {
 | 
				
			||||||
 | 
					    "collapsed": false,
 | 
				
			||||||
 | 
					    "pycharm": {
 | 
				
			||||||
 | 
					     "name": "#%%\n"
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					   }
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
  {
 | 
					  {
 | 
				
			||||||
   "cell_type": "code",
 | 
					   "cell_type": "code",
 | 
				
			||||||
   "execution_count": null,
 | 
					   "execution_count": null,
 | 
				
			||||||
@ -318,7 +337,7 @@
 | 
				
			|||||||
    "\n",
 | 
					    "\n",
 | 
				
			||||||
    "retriever.train(\n",
 | 
					    "retriever.train(\n",
 | 
				
			||||||
    "    data_dir=doc_dir,\n",
 | 
					    "    data_dir=doc_dir,\n",
 | 
				
			||||||
    "    train_filename=dev_filename,\n",
 | 
					    "    train_filename=train_filename,\n",
 | 
				
			||||||
    "    dev_filename=dev_filename,\n",
 | 
					    "    dev_filename=dev_filename,\n",
 | 
				
			||||||
    "    test_filename=dev_filename,\n",
 | 
					    "    test_filename=dev_filename,\n",
 | 
				
			||||||
    "    n_epochs=1,\n",
 | 
					    "    n_epochs=1,\n",
 | 
				
			||||||
 | 
				
			|||||||
@ -61,7 +61,7 @@ def tutorial9_dpr_training():
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    retriever.train(
 | 
					    retriever.train(
 | 
				
			||||||
        data_dir=doc_dir,
 | 
					        data_dir=doc_dir,
 | 
				
			||||||
        train_filename=dev_filename,
 | 
					        train_filename=train_filename,
 | 
				
			||||||
        dev_filename=dev_filename,
 | 
					        dev_filename=dev_filename,
 | 
				
			||||||
        test_filename=dev_filename,
 | 
					        test_filename=dev_filename,
 | 
				
			||||||
        n_epochs=1,
 | 
					        n_epochs=1,
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user