Coder Social home page Coder Social logo

top's Introduction

TOP: Topology Optimization Process

Dataset used in "Neural Networks for Topology Optimization" [link][pdf][code]

Download (~3 Gb) Yandex Drive

The dataset of topology optimization process. It contains the precise solutions of 10,000 randomly stated problems. Each object is a tensor of shape (100, 40, 40): 100 iterations, 40×40 grid.

How it is generated

We used Topy for the generation of the current dataset. It is based on SIMP approach.

The constraints and loads for each of the problem are chosen in the following way:

  • The number of nodes with fixed x and y translations and the number of loads are sampled from the Poisson distribution:
  • The nodes for each of the above described constraints are sampled from the distribution defined on the grid. The probability to choose the boundary node is 100 times higher than that for inner node.
  • The load values are chosen as -1
  • The volume fraction is sampled from the Gaussian distribution with mean of 0.5 and std of 0.1

You can generate your own dataset just by using scripts from code/ folder. sampler.py defines all the required distributions, and generate_data.py is just a convenient wrapper for ToPy. Install ToPy and run:

python code/generate_data.py --dir DIR_TO_SAVE --num NUMBER_OF_SAMPLES

How to use

Each tensor is stored in compressed format .npz. It could be extracted easily with numpy:

import numpy as np

data = np.load(PATH_TO_FILE)['arr_0']

We recommend to use horizontal and vertical flips as well as 90° rotation to augment the initial dataset. These operations allow one to get the dataset of 80,000 objects.

Citation

Please cite our work if you write a scientific paper using this code and/or dataset.

@article{sosnovik2017neural,
  title={Neural networks for topology optimization},
  author={Sosnovik, Ivan and Oseledets, Ivan},
  journal={arXiv preprint arXiv:1709.09578},
  year={2017}
}

top's People

Contributors

isosnovik avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

top's Issues

Logging issue

It says

Traceback (most recent call last):
File "generate_data.py", line 10, in
topy.Logger.verbose = False
AttributeError: 'module' object has no attribute 'Logger'

when I run generate_data.py code

Is A Directory Error: when extracting the data in .npz format

Hi,

I am using 500 datapoints from the dataset you have provided to try and run the experiments for an academic project. But I am getting the following error when I try to extract the data:

Is a directory error

I have saved the dataset in the same directory as that of the jupyter notebook. Please suggest a correction.

Thanks in advance!

SUPERLU_MALLOC fails for buf in intCalloc() at line 71 in file pysparse\direct\superlu\src\memory.c

Thank you for your valuable work on topology! When I was runner the code on my computer ,it raised an error, as follows :
(py27) PS D:\topo\top-master> python code/generate_data.py --dir C:\tmp\data_topy --num 10000
Generating the dataset...
D:\anaconda\install\envs\py27\lib\site-packages\topy\topology.py:517: RuntimeWarning: invalid value encountered in power
(self.desvars * (-self.df / lammid)**self.eta)**self.q))))
D:\anaconda\install\envs\py27\lib\site-packages\topy\topology.py:517: RuntimeWarning: invalid value encountered in minimum
(self.desvars * (-self.df / lammid)**self.eta)**self.q))))
D:\anaconda\install\envs\py27\lib\site-packages\topy\topology.py:517: RuntimeWarning: invalid value encountered in maximum
(self.desvars * (-self.df / lammid)self.eta)self.q))))
D:\anaconda\install\envs\py27\lib\site-packages\topy\topology.py:581: RuntimeWarning: invalid value encountered in double_scalars
updatedKe = self.desvars[ely, elx] ** self.p * self.Ke
Done: 891/10000Can't expand MemType 0: jcol 1627
Done: 891/10000Can't expand MemType 0: jcol 3186
Done: 891/10000Can't expand MemType 0: jcol 2500.
Done: 891/10000SUPERLU_MALLOC fails for buf in intCalloc() at line 71 in file pysparse\direct\superlu\src\memory.c

I need your help about how to fix the bug, thanks very much!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.