Skip to content

Instantly share code, notes, and snippets.

bl_info = {
"name": "FreeCAD Importer",
"category": "Import-Export",
"author": "Yorik van Havre",
"version": (4, 0, 0),
"blender": (2, 80, 0),
"location": "File > Import > FreeCAD",
"description": "Imports a .FCStd file from FreeCAD",
"warning": "You need a version of FreeCAD compiled with the same Python version as Blender. Only Part- and Mesh-based objects are supported at the moment",
}
@rako233
rako233 / spectre.c
Created January 5, 2018 04:16 — forked from ErikAugust/spectre.c
Spectre example code
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#ifdef _MSC_VER
#include <intrin.h> /* for rdtscp and clflush */
#pragma optimize("gt",on)
#else
#include <x86intrin.h> /* for rdtscp and clflush */
#endif
@rako233
rako233 / residual_network.py
Created November 3, 2017 21:26 — forked from mjdietzx/residual_network.py
Clean and simple Keras implementation of residual networks (ResNeXt and ResNet) accompanying accompanying Deep Residual Learning: https://blog.waya.ai/deep-residual-learning-9610bb62c355.
"""
Clean and simple Keras implementation of network architectures described in:
- (ResNet-50) [Deep Residual Learning for Image Recognition](https://arxiv.org/pdf/1512.03385.pdf).
- (ResNeXt-50 32x4d) [Aggregated Residual Transformations for Deep Neural Networks](https://arxiv.org/pdf/1611.05431.pdf).
Python 3.
"""
from keras import layers
from keras import models
@rako233
rako233 / one_hot_lambda_layer_keras.py
Created October 22, 2017 14:32 — forked from bzamecnik/one_hot_lambda_layer_keras.py
One-hot encoding in a Keras Lambda layer
"""
When traing ML models on text we usually need to represent words/character in one-hot encoding.
This can be done in preprocessing, however it may make the dataset file bigger. Also when we'd
like to use an Embedding layer, it accepts the original integer indexes instead of one-hot codes.
Can be move the one-hot encoding from pre-preprocessing directly into the model?
If so we could choose from two options: use one-hot inputs or perform embedding.
A way how to do this was suggested in Keras issue [#3680](https://github.com/fchollet/keras/issues/3680).
@rako233
rako233 / nodetest.py
Created July 10, 2017 19:06 — forked from OEP/nodetest.py
Basic script for Blender Python nodes
import bpy
from bpy.props import IntProperty, FloatProperty, PointerProperty
import nodeitems_utils
from nodeitems_utils import NodeItem, NodeCategory
bl_info = {
"name": "Custom nodes",
"category": "Node",
}