<commit_before>{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Caffe2 Basic Concepts - Operators & Nets\n",
    "\n",
    "In this tutorial we will go through a set of Caffe2 basics: the basic concepts including how operators and nets are being written.\n",
    "\n",
    "First, let's import caffe2. `core` and `workspace` are usually the two that you need most. If you want to manipulate protocol buffers generated by caffe2, you probably also want to import `caffe2_pb2` from `caffe2.proto`."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": false
   },
   "outputs": [],
   "source": [
    "# We'll also import a few standard python libraries\n",
    "from matplotlib import pyplot\n",
    "import numpy as np\n",
    "import time\n",
    "\n",
    "# These are the droids you are looking for.\n",
    "from caffe2.python import core, workspace\n",
    "from caffe2.proto import caffe2_pb2"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "You might see a warning saying that caffe2 does not have GPU support. That means you are running a CPU-only build. Don't be alarmed - anything CPU is still runnable without problem."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "## Workspaces\n",
    "\n",
    "Let's cover workspaces first, where all the data reside.\n",
    "\n",
    "If you are familiar with Matlab, workspace consists of blobs you create and store in memory. For now, consider a blob to be a N-dimensional Tensor similar to numpy's ndarray, but is contiguous. Down the road, we will show you that a blob is actually a typed pointer that can store any type of C++ objects, but Tensor is the most common type stored in a blob. Let's show what the interface looks like.\n",
    "\n",
    "`Blobs()` prints out all existing blobs in the workspace. \n",
    "`HasBlob()` queries if a blob exists in the workspace. For now, we don't have anything yet."
   ]<commit_msg>Fix not showing histogram in Basics.ipynb<commit_after>{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Caffe2 Basic Concepts - Operators & Nets\n",
    "\n",
    "In this tutorial we will go through a set of Caffe2 basics: the basic concepts including how operators and nets are being written.\n",
    "\n",
    "First, let's import caffe2. `core` and `workspace` are usually the two that you need most. If you want to manipulate protocol buffers generated by caffe2, you probably also want to import `caffe2_pb2` from `caffe2.proto`."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": false
   },
   "outputs": [],
   "source": [
    "# We'll also import a few standard python libraries\n",
    "from matplotlib import pyplot\n",
    "import numpy as np\n",
    "import time\n",
    "\n",
    "# These are the droids you are looking for.\n",
    "from caffe2.python import core, workspace\n",
    "from caffe2.proto import caffe2_pb2\n",
    "\n",
    "# Let's show all plots inline.\n",
    "%matplotlib inline"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "You might see a warning saying that caffe2 does not have GPU support. That means you are running a CPU-only build. Don't be alarmed - anything CPU is still runnable without problem."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "## Workspaces\n",
    "\n",
    "Let's cover workspaces first, where all the data reside.\n",
    "\n",
    "If you are familiar with Matlab, workspace consists of blobs you create and store in memory. For now, consider a blob to be a N-dimensional Tensor similar to numpy's ndarray, but is contiguous. Down the road, we will show you that a blob is actually a typed pointer that can store any type of C++ objects, but Tensor is the most common type stored in a blob. Let's show what the interface looks like.\n",
    "\n",
    "`Blobs()` prints out all existing blobs in the workspace. \n",
    "`HasBlob()` queries if a blob exists in the workspace. For now, we don't have anything yet."
   ]
{'fraction_non_alphanumeric': 0.12080378250591016, 'fraction_numerical': 0.005673758865248227, 'mean_word_length': 3.0218631178707223, 'pattern_counts': {'":': 34, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4806110', 'n_tokens_mistral': 1333, 'n_tokens_neox': 1272, 'n_words': 551}