Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma
You can get the list of supported formats with:
ffmpeg -formats
You can get the list of installed codecs with:
'use strict' | |
const Fs = require('fs') | |
const Path = require('path') | |
const Axios = require('axios') | |
async function downloadImage () { | |
const url = 'https://unsplash.com/photos/AaEQmoufHLk/download?force=true' | |
const path = Path.resolve(__dirname, 'images', 'code1.jpg') |
[MemoryDiagnoser(false)] | |
public class Benchmarks | |
{ | |
private readonly IAppCache _appCache = new CachingService(); | |
private readonly IMemoryCache _memoryCache = new MemoryCache(new MemoryCacheOptions()); | |
[Benchmark] | |
public int GetOrCreate_MemoryCache() => | |
_memoryCache.GetOrCreate("set", _ => 100); | |
[Benchmark] |
namespace CarrierOnboarding.Mfe.Infrastructure | |
{ | |
public static class AuthenticationExtensions | |
{ | |
public static AuthenticationBuilder AddMktpCookieAuthentication(this IServiceCollection services) | |
{ | |
void DefaultOptions(AuthenticationOptions options) | |
{ | |
options.DefaultAuthenticateScheme = CookieAuthenticationDefaults.AuthenticationScheme; | |
options.DefaultSignInScheme = CookieAuthenticationDefaults.AuthenticationScheme; |
More info
using System; | |
namespace FunCSharp | |
{ | |
public static class Extensions | |
{ | |
// x => f(g(x)) | |
public static Func<T1, T3> ComposeWith<T1, T2, T3>(this Func<T2, T3> f, Func<T1, T2> g) | |
{ | |
return x => f(g(x)); |
#List unique values in a DataFrame column | |
pd.unique(df.column_name.ravel()) | |
#Convert Series datatype to numeric, getting rid of any non-numeric values | |
df['col'] = df['col'].astype(str).convert_objects(convert_numeric=True) | |
#Grab DataFrame rows where column has certain values | |
valuelist = ['value1', 'value2', 'value3'] | |
df = df[df.column.isin(value_list)] |