Skip to content

Instantly share code, notes, and snippets.

@eqs
Created March 30, 2016 15:47
Show Gist options
  • Save eqs/f160215d0fe9763379b65df7d6227d5d to your computer and use it in GitHub Desktop.
Save eqs/f160215d0fe9763379b65df7d6227d5d to your computer and use it in GitHub Desktop.
データセットを生成するスクリプト
# -*- coding: utf-8 -*-
"""
Created on 03/31/16 00:31:59
円状のデータセットを生成するスクリプト
@author: eqs
"""
import sys
import numpy as np
import matplotlib.pyplot as plt
import sklearn.datasets as datasets
np.random.seed(0)
points, labels = datasets.make_circles(n_samples=1000, shuffle=False, noise=0.075, factor=0.6)
data = np.c_[points, labels]
np.savetxt('dataset.txt', data)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment