This file contains hidden or 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
| import mujoco | |
| import time | |
| import jax | |
| from mujoco import mjx | |
| import argparse | |
| argparser = argparse.ArgumentParser() | |
| argparser.add_argument("--xml", help="Path to scene", type=str, required=True) | |
| argparser.add_argument("--n", help="Parallel GPU instances", type=int, default=1024) | |
| argparser.add_argument( |
This file contains hidden or 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
| # Can be use to send an url (e.g: http://.../movie.mp4) to your Kodi media center | |
| # You have to enable HTTP control (without password) | |
| # This can be used on an Android Phone with pyDroid (don't forget to pip install requests) | |
| import requests | |
| # Kodi IP address | |
| kodi = "192.168.1.34" | |
| url = input("Enter URL: ") |
This file contains hidden or 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
| import time | |
| import numpy as np | |
| import meshcat | |
| import meshcat.geometry as g | |
| import meshcat.transformations as tf | |
| vis = meshcat.Visualizer() | |
| cylinders: dict = {} |
This file contains hidden or 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
| Test |
This file contains hidden or 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
| import matplotlib.pyplot as plt | |
| import numpy as np | |
| from scipy.integrate import solve_ivp | |
| a, y0, g0 = 3, 100, 100 | |
| T = np.linspace(0, 30, 30) | |
| gs = [] | |
| for t in T: | |
| # G depends on Y |
This file contains hidden or 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
| def f(x): | |
| return 123 |
This file contains hidden or 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
| static void listerLesFilms() | |
| { | |
| String requete = "SELECT nom, annee FROM movies"; | |
| try { | |
| Statement stmt = connexion.createStatement(); | |
| ResultSet results = stmt.executeQuery(requete); | |
| while (results.next()) { | |
| System.out.println("* Film, nom: "+results.getString("nom")+", année: "+results.getString("annee")); | |
| } |
This file contains hidden or 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
| using System; | |
| using System.IO; | |
| using System.Net; | |
| using System.Net.Sockets; | |
| using System.Text; | |
| class Program | |
| { | |
| public static void Main() | |
| { |
This file contains hidden or 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
| using System; | |
| using System.IO; | |
| using System.Net; | |
| using System.Net.Sockets; | |
| using System.Text; | |
| class Program | |
| { | |
| public static void Main() | |
| { |
This file contains hidden or 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
| <?php | |
| class A { | |
| private $x; | |
| public function __sleep() { | |
| return ['x']; | |
| } | |
| } | |
| class B extends A { |
NewerOlder