forked from zoranzhao/DeepThings
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
1,003 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
OPENMP=1 | ||
VPATH=./src | ||
DARKIOT=../DarkIoT | ||
DARKNET=../nnpack_darknet/darknet-nnpack | ||
OBJDIR=./obj/ | ||
EXEC=deep | ||
DARKNETLIB=libdarknet.a | ||
DARKIOTLIB=libdarkiot.a | ||
|
||
CC=gcc | ||
LDFLAGS= -lm -pthread | ||
CFLAGS=-Wall -fPIC | ||
COMMON=-I$(DARKIOT)/include/ -I$(DARKIOT)/src/ -I$(DARKNET)/include/ -I$(DARKNET)/src/ -Iinclude/ -Isrc/ | ||
LDLIB=-L$(DARKIOT) -l:$(DARKIOTLIB) -L$(DARKNET) -l:$(DARKNETLIB) | ||
|
||
ifeq ($(OPENMP), 1) | ||
CFLAGS+= -fopenmp | ||
endif | ||
|
||
ifeq ($(DEBUG), 1) | ||
OPTS+=-O0 -g | ||
else | ||
OPTS+=-Ofast | ||
endif | ||
|
||
ifeq ($(ARM_NEON), 1) | ||
COMMON+= -DARM_NEON | ||
CFLAGS+= -DARM_NEON -mfpu=neon-vfpv4 -funsafe-math-optimizations -ftree-vectorize | ||
endif | ||
|
||
CFLAGS+=$(OPTS) | ||
OBJS = configure.o top.o ftp.o inference_engine_helper.o | ||
EXECOBJ = $(addprefix $(OBJDIR), $(OBJS)) | ||
DEPS = $(wildcard */*.h) Makefile | ||
|
||
all: obj $(EXEC) | ||
|
||
$(EXEC): $(EXECOBJ) $(DARKNETLIB) $(DARKIOTLIB) | ||
$(CC) $(COMMON) $(CFLAGS) $(EXECOBJ) -o $@ $(LDLIB) $(LDFLAGS) | ||
|
||
$(DARKNETLIB): | ||
$(MAKE) -C $(DARKNET) | ||
|
||
$(DARKIOTLIB): | ||
$(MAKE) -C $(DARKIOT) | ||
|
||
$(OBJDIR)%.o: %.c $(DEPS) | ||
$(CC) $(COMMON) $(CFLAGS) -c $< -o $@ | ||
|
||
obj: | ||
mkdir -p obj | ||
|
||
test: | ||
./deep ${ARGS} | ||
|
||
.PHONY: clean | ||
|
||
clean: | ||
rm -rf $(EXEC) $(EXECOBJ) *.log $(OBJDIR) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
classes= 80 | ||
train = /home/pjreddie/data/coco/trainvalno5k.txt | ||
#valid = coco_testdev | ||
valid = data/coco_val_5k.list | ||
names = data/coco.names | ||
backup = /home/pjreddie/backup/ | ||
eval=coco | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#ifndef CONFIGURE_H | ||
#define CONFIGURE_H | ||
|
||
/*Partitioning paramters*/ | ||
#define FUSED_LAYERS_MAX 16 | ||
#define PARTITIONS_W_MAX 6 | ||
#define PARTITIONS_H_MAX 6 | ||
#define PARTITIONS_MAX 36 | ||
#define THREAD_NUM 1 | ||
#include <stdint.h> | ||
|
||
extern uint32_t fused_layers; | ||
extern uint32_t partitions; | ||
extern uint32_t partitions_w; | ||
extern uint32_t partitions_h; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,258 @@ | ||
[net] | ||
# Testing | ||
batch=1 | ||
subdivisions=1 | ||
# Training | ||
# batch=64 | ||
# subdivisions=8 | ||
width=608 | ||
height=608 | ||
channels=3 | ||
momentum=0.9 | ||
decay=0.0005 | ||
angle=0 | ||
saturation = 1.5 | ||
exposure = 1.5 | ||
hue=.1 | ||
|
||
learning_rate=0.001 | ||
burn_in=1000 | ||
max_batches = 500200 | ||
policy=steps | ||
steps=400000,450000 | ||
scales=.1,.1 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=32 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[maxpool] | ||
size=2 | ||
stride=2 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=64 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[maxpool] | ||
size=2 | ||
stride=2 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=128 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=64 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=128 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[maxpool] | ||
size=2 | ||
stride=2 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=256 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=128 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=256 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[maxpool] | ||
size=2 | ||
stride=2 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=512 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=256 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=512 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=256 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=512 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[maxpool] | ||
size=2 | ||
stride=2 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=1024 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=512 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=1024 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=512 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
filters=1024 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
activation=leaky | ||
|
||
|
||
####### | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
filters=1024 | ||
activation=leaky | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
filters=1024 | ||
activation=leaky | ||
|
||
[route] | ||
layers=-9 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
filters=64 | ||
activation=leaky | ||
|
||
[reorg] | ||
stride=2 | ||
|
||
[route] | ||
layers=-1,-4 | ||
|
||
[convolutional] | ||
batch_normalize=1 | ||
size=3 | ||
stride=1 | ||
pad=1 | ||
filters=1024 | ||
activation=leaky | ||
|
||
[convolutional] | ||
size=1 | ||
stride=1 | ||
pad=1 | ||
filters=425 | ||
activation=linear | ||
|
||
|
||
[region] | ||
anchors = 0.57273, 0.677385, 1.87446, 2.06253, 3.33843, 5.47434, 7.88282, 3.52778, 9.77052, 9.16828 | ||
bias_match=1 | ||
classes=80 | ||
coords=4 | ||
num=5 | ||
softmax=1 | ||
jitter=.3 | ||
rescore=1 | ||
|
||
object_scale=5 | ||
noobject_scale=1 | ||
class_scale=1 | ||
coord_scale=1 | ||
|
||
absolute=1 | ||
thresh = .6 | ||
random=1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#include "configure.h" | ||
|
||
uint32_t fused_layers; | ||
uint32_t partitions; | ||
uint32_t partitions_w; | ||
uint32_t partitions_h; | ||
|
Oops, something went wrong.