Skip to content

Instantly share code, notes, and snippets.

@Mizux
Mizux / argonaute.xml
Last active February 6, 2018 14:44
QTCreator style
<?xml version="1.0" encoding="UTF-8"?>
<style-scheme version="1.0" name="argonaute">
<style name="Text" foreground="#aaaaaa" background="#000000"/>
<style name="Link" foreground="#0055ff"/>
<style name="Selection" foreground="#000000" background="#aaaaaa"/>
<style name="LineNumber" foreground="#888888" background="#232323"/>
<style name="SearchResult" background="#555500"/>
<style name="SearchScope" background="#222200"/>
<style name="Parentheses" foreground="#ff5555" background="#333333"/>
<style name="ParenthesesMismatch" background="#800080"/>
@Mizux
Mizux / mouse.xml
Last active February 6, 2018 14:44
QTCreator style
<?xml version="1.0" encoding="UTF-8"?>
<style-scheme version="1.0" name="Mouse">
<style name="Text" foreground="#aaaaaa" background="#000000"/>
<style name="Link" foreground="#0055ff"/>
<style name="Selection" foreground="#000000" background="#aaaaaa"/>
<style name="LineNumber" foreground="#888888" background="#232323"/>
<style name="SearchResult" background="#555500"/>
<style name="SearchScope" background="#222200"/>
<style name="Parentheses" foreground="#ff5555" background="#333333"/>
<style name="ParenthesesMismatch" background="#800080"/>
@Mizux
Mizux / forest.xml
Last active February 6, 2018 14:43
QTCreator style
<?xml version="1.0" encoding="UTF-8"?>
<style-scheme version="1.0" name="Forest">
<style name="Text" foreground="#bac05f" background="#101010"/>
<style name="Link" foreground="#0055ff"/>
<style name="Selection" foreground="#000000" background="#aaaaaa"/>
<style name="LineNumber" foreground="#888888" background="#232323"/>
<style name="SearchResult" foreground="#000000" background="#ffffff"/>
<style name="SearchScope" background="#222200"/>
<style name="Parentheses" foreground="#ff5555" background="#333333"/>
<style name="CurrentLine" background="#232323"/>
@Mizux
Mizux / vrp_unload.py
Last active September 30, 2021 17:46
vrp with unload at duplicated depot...
#!/usr/bin/env python
# This Python file uses the following encoding: utf-8
# Copyright 2015 Tin Arm Engineering AB
# Copyright 2018 Google LLC
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Coin-OR CMake target dependencies.
# You can generate png image using `plantuml -Tpng deps.dot`
@startdot
digraph Make {
rankdir=BT;
subgraph clusterCoinUtils {
node [shape=box, style=rounded];
CoinUtils [label="Coin::CoinUtils", color=royalblue];
color=royalblue;
label = "CoinUtils.git";
@Mizux
Mizux / vrp_collect_deliver.py
Last active April 18, 2024 08:14
VRP Collect and Deliver
#!/usr/bin/env python3
"""Capacited Vehicles Routing Problem (CVRP)."""
from ortools.constraint_solver import routing_enums_pb2
from ortools.constraint_solver import pywrapcp
def create_data_model():
"""Stores the data for the problem."""
data = {}
# 1 Depot: S, 10 Deliveries D0-D9, 6 Pickups P0-P5
@Mizux
Mizux / 01_unity_linux_crash_report.md
Last active May 28, 2020 07:55
[Linux] Unity Startup Crash

Summary

On a newly archlinux, I can't run the Editor on any project.

Protocol

  1. Download the UnityHub.app from here

  2. Install any Unity Editor note: I've tested using UnityHub 2018.4.22f1, 2019.3.11f1 and 2020.2.0a8) note2: I also installed the version 2019.1.0f2 from the forum topic Unity on Linux: Release Notes and Known Issues

@Mizux
Mizux / vrp_collect_deliveries.py
Last active November 22, 2022 18:33
VRP with Collects and Deliveries
#!/usr/bin/env python3
"""Capacitated Vehicle Routing Problem (CVRP)."""
from ortools.constraint_solver import pywrapcp
from ortools.constraint_solver import routing_enums_pb2
###########################
# Problem Data Definition #
###########################
def create_data_model():
@Mizux
Mizux / vrp_multiple_transit.py
Last active November 6, 2023 19:37
VRP With differents speed and autonomy
#!/usr/bin/env python3
"""Vehicles Routing Problem (VRP)."""
from functools import partial
from ortools.constraint_solver import routing_enums_pb2
from ortools.constraint_solver import pywrapcp
# Vehicle 1: slow (speed: 20)
# Vehicle 2: slow (speed: 20)
# Vehicle 3: average (speed: 18)
@Mizux
Mizux / MemoryLeakSolver.java
Last active September 30, 2021 17:46
OR-Tools Java MemoryLeakSolver
// Copyright 2010-2018 Google LLC
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.